Compiler Explorer
Lets your AI agent compile code with many compilers and look at the assembly it produces.
19k stars on GitHubby Compiler Explorer project (Matt Godbolt and contributors)License BSD-2-ClauseUpdated 18 days ago
How to install
This MCP is remote: it runs in the cloud.
Nothing to install. Copy the address and paste it into your AI app:
Server address
https://godbolt.org/mcp
- βΊClaude (site or app): Settings β Connectors β Add custom connector.
- βΊChatGPT: Settings β Apps β Create app (developer mode), and paste the address.
- βΊClaude Code, Cursor, VS Code and Windsurf: pick your app below.
Paste in the terminal:
claude mcp add --transport http compiler-explorer https://godbolt.org/mcp
Ready! Now test it
Restart the app and paste one of these requests in the chat:
Compile this C++ function with GCC and Clang and show me the assembly for both.
Which compilers are available for Rust, and how does my loop look after compiling?
What it is
Compiler Explorer is the godbolt.org website where you edit code in C, C++, Rust, Go, Python, Java and 30+ other languages and see how it looks after compiling. The registry lists an MCP server for it, so an agent can compile code and inspect the result. The project also has a REST API for compiling to assembly and listing compilers.
What it can do
- Compile code to assembly with many compilers
- List available compilers and languages (REST API)
- Share godbolt.org links (from the registry description)
When to use
- βΊWhen you want to see what assembly a piece of C++ or Rust code turns into.
- βΊWhen you want to compare how two compilers or compiler options treat the same code.
- βΊWhen you want your agent to share a link that shows a compiled example.
What you need
Skills that pair well
MCP or skill?
The MCP gives the agent the hands. The skill teaches the right way to use them. Together, the result is better and uses fewer tokens.
binary-analysis-patternsTeaches your agent to analyze compiled programs. It learns to understand assembly code and reconstruct the logic of complex programs.exploring-llm-evaluationsHelps your agent inspect the automatic checks that score your AI responses, including code rules, AI judges and sentiment, and explain failures.check-compiler-errorsRuns your project's compile and type checks, groups the errors by file, and fixes the most certain ones first until the build is clean.Frequently asked questions
Is it free and open source?
The readme describes Compiler Explorer as an open project you can run yourself, and the public site godbolt.org is available to use. The project accepts donations through Patreon, GitHub Sponsors and PayPal.
Which languages does it support?
It lists C, C++, C#, F#, Rust, Go, D, Haskell, Swift, Pascal, ispc, Python, Java and more, over 30 languages in total.
Can I run it on my own machine?
Yes. With a compatible Node.js installed, running make starts a local instance on port 10240.
Does the readme explain the MCP setup?
No. The readme covers the website and its REST API; the MCP server comes from the registry description, so check the project docs for connection steps.
Is there an API?
Yes. The readme says there is a simple RESTful API to compile to assembly and list compilers, documented in docs/API.md.
How much is it used?
The readme says the public site serves over 3,000,000 compilations per week.
If it does not work
- βΊIf a local run fails, check that your Node.js version is at least the one pinned in .node-version.
- βΊLanguages that need demangling tools (such as Rust, D or Haskell) need extra tools from the separate tools repo.
- βΊIf a compiler is missing locally, add it through a LANG.local.properties file or the CE Properties Wizard.
5 new skills a week. 1 minute to read.