
Go Playground
Execute Go code remotely using the official Go Playground API and share code snippets with public URLs.
Enables remote execution of Go code using the official Go Playground API with tools for running code with optional vet checking, sharing snippets via public URLs, and combining execution with sharing for immediate testing and distribution.
What it does
- Execute Go code in sandbox environment
- Generate shareable URLs for Go snippets
- Read code from existing Go Playground URLs
- Run code with optional vet checking
- Combine execution and sharing in single operation
Best for
About Go Playground
Go Playground is a community-built MCP server published by samber that provides AI assistants with tools and capabilities via the Model Context Protocol. Run and share Go code instantly with Go Playground. Features include code execution, vet checking, and public URLs for e It is categorized under developer tools. This server exposes 5 tools that AI clients can invoke during conversations and coding sessions.
How to install
You can install Go Playground in your AI client of choice. Use the install panel on this page to get one-click setup for Cursor, Claude Desktop, VS Code, and other MCP-compatible clients. This server runs locally on your machine via the stdio transport.
License
Go Playground is released under the MIT license. This is a permissive open-source license, meaning you can freely use, modify, and distribute the software.
Tools (5)
Run Go code in the Go Playground and return execution results
Share Go code and get a shareable URL
Run Go code and get both execution results and a shareable URL
Read Go code from an existing Go Playground URL
Execute Go code from an existing Go Playground URL
Go Playground MCP Server
A Model Context Protocol (MCP) server that integrates with the Go Playground API to execute Go code and generate shareable URLs.
🧙 Features
- Run Go Code: Execute Go code in the Go Playground sandbox
- Share Code: Generate shareable URLs for Go code snippets
- Run and Share: Execute code and get both results and share URL in one operation
- Read from URL: Read Go code from existing Go Playground URLs
- Execute from URL: Execute Go code from existing Go Playground URLs
- MCP Integration: Full Model Context Protocol compliance
🏃♂️ Usage
The server can be used with any MCP-compatible client. The server provides five tools:
run_go_code- Execute Go code and return resultsshare_go_code- Share Go code and get a URLrun_and_share_go_code- Execute code and get both results and share URLread_go_playground_url- Read Go code from an existing Go Playground URLexecute_go_playground_url- Execute Go code from an existing Go Playground URL
Add this to your MCP client configuration:
{
"mcpServers": {
"go-playground": {
"command": "npx",
"args": ["-y", "go-playground-mcp"]
}
}
}
Examples
Reading code from a Go Playground URL
// Read code from https://go.dev/play/xyz123
const result = await mcpClient.callTool("read_go_playground_url", {
url: "https://go.dev/play/xyz123"
});
Executing code from a Go Playground URL
// Execute code from https://go.dev/play/xyz123
const result = await mcpClient.callTool("execute_go_playground_url", {
url: "https://go.dev/play/xyz123",
withVet: true
});
URL Formats Supported
The new URL-based tools support these Go Playground URL formats:
https://go.dev/play/<snippet-id>https://go.dev/play/p/<snippet-id>https://play.golang.org/p/<snippet-id>
🤝 Contributing
- Ping me on Twitter @samuelberthe (DMs, mentions, whatever :))
- Fork the project
- Fix open issues or request new features
Don't hesitate ;)
Install
- Clone this repository:
git clone https://github.com/samber/go-playground-mcp.git
cd go-playground-mcp
- Install dependencies:
npm install
- Build the project:
npm run build
Running the Server
# Development mode
npm run dev
# Production mode
npm run build
npm start
Add this to your MCP client configuration:
{
"mcpServers": {
"go-playground": {
"command": "node",
"args": ["dist/index.js"]
}
}
}
👤 Contributors
💫 Show your support
Give a ⭐️ if this project helped you!
📝 License
Copyright © 2025 Samuel Berthe.
This project is MIT licensed.
Alternatives
Related Skills
Browse all skillsUI design system toolkit for Senior UI Designer including design token generation, component documentation, responsive design calculations, and developer handoff tools. Use for creating design systems, maintaining visual consistency, and facilitating design-dev collaboration.
Guide for building TypeScript CLIs with Bun. Use when creating command-line tools, adding subcommands to existing CLIs, or building developer tooling. Covers argument parsing, subcommand patterns, output formatting, and distribution.
Use when working with the OpenAI API (Responses API) or OpenAI platform features (tools, streaming, Realtime API, auth, models, rate limits, MCP) and you need authoritative, up-to-date documentation (schemas, examples, limits, edge cases). Prefer the OpenAI Developer Documentation MCP server tools when available; otherwise guide the user to enable `openaiDeveloperDocs`.
Master API documentation with OpenAPI 3.1, AI-powered tools, and modern developer experience practices. Create interactive docs, generate SDKs, and build comprehensive developer portals. Use PROACTIVELY for API documentation or developer portal creation.
Integrate Vercel AI SDK applications with You.com tools (web search, AI agent, content extraction). Use when developer mentions AI SDK, Vercel AI SDK, generateText, streamText, or You.com integration with AI SDK.
Use when building MCP servers or clients that connect AI systems with external tools and data sources. Invoke for MCP protocol compliance, TypeScript/Python SDKs, resource providers, tool functions.