Describe a sound in plain English. Hear it in Surge XT seconds later.
Quick start · Install · Tools · Troubleshooting · Changelog
Surge XT MCP is a Model Context Protocol server that lets an AI assistant design sounds, browse patches and play notes on Surge XT, the free open-source hybrid synthesizer. It drives your running synth through Surge XT's own OSC interface, in the standalone app or inside your DAW, and reads every change back, so the assistant tells you what Surge XT did.
What you can do
- Design a sound from a sentence.
design_soundturns "dark punchy reese bass" or "wide evolving pad with reverb" into a recipe you can read: every step names its value in Hz, seconds, cents or dB and says why.apply_recipesends it and confirms each step with Surge XT. - Understand any patch.
describe_patchreads the whole sound in one call: oscillators, filters, envelopes, effects, macros and modulation, in Surge XT's own units. - Shape it live. Friendly controls for filters, envelopes, macros, effects, wavetables and modulation, plus direct access to all 770+ Surge XT parameters.
- Play it. Notes, chords, melodies, microtonal pitches and timed polyphonic scores with per-note pitch, pan, volume, timbre and pressure.
- Browse the library offline. Search the factory, third-party and user patches (over 3,000 on a standard install) by name, category or author pack, then load, step, randomize and save.
- Retune it. Browse and load Scala scales and keyboard mappings, and return to concert pitch in one call.
- Render to WAV. Optional headless rendering through the
surgepybindings. Without them the tool says so. It never fakes audio.
Quick start
1. Set up Surge XT
Install Surge XT 1.3.4 and open it, standalone or as a plugin. In Menu → OSC Settings enable:
- OSC In on port
53280 - OSC Out to
127.0.0.1on port53281
Keep Surge XT open while you use the live tools. Patch browsing, recipes and the parameter catalog work without it.
2. Install uv
The server runs through uv, which fetches it from PyPI together with its Python on first start. Nothing else to install.
3. Add the server to your MCP client
Every client runs the same command:
uvx surge-xt-mcp
Pick your client under Add the server to your MCP client for the exact setup.
4. Run a sound check
Ask your assistant:
Run a Surge XT sound check.
It reports the server version, the patch libraries it found and the OSC connection, then plays a C major chord. If you hear it, you are ready:
Design a dark punchy bass in Surge XT, play a low riff so I can hear it, then save it as Midnight Reese.
Add the server to your MCP client
Most clients share one JSON shape. Where a section below says "the standard block", it means this:
{
"mcpServers": {
"surge-xt": {
"command": "uvx",
"args": ["surge-xt-mcp"]
}
}
}
If Surge XT uses other OSC ports, append them to args: "--osc-send-port", "48000", "--osc-recv-port", "48001".
The claude, codex, gemini, grok, opencode and code commands below were run with these arguments against scratch configurations. The other entries follow each client's documentation as of November 2026.
Claude Desktop
Open Settings → Developer → Edit Config, add the standard block to claude_desktop_config.json and restart Claude Desktop. Example file
Claude Code
claude mcp add surge-xt -- uvx surge-xt-mcp
Add --scope user to use it in every project. To share it with a repository, put the standard block in .mcp.json at the repository root.
Cursor
Add the standard block to ~/.cursor/mcp.json, or to .cursor/mcp.json in a project. Example file
VS Code (GitHub Copilot)
code --add-mcp '{"name":"surge-xt","command":"uvx","args":["surge-xt-mcp"]}'
The quotes above suit Bash and Zsh. To add it by hand, put this in .vscode/mcp.json, which uses a servers key. Example file
{
"servers": {
"surge-xt": {
"type": "stdio",
"command": "uvx",
"args": ["surge-xt-mcp"]
}
}
}
Current VS Code builds also read the standard block from .mcp.json at the workspace root.
Codex CLI
codex mcp add surge-xt -- uvx surge-xt-mcp
Or add it to ~/.codex/config.toml:
[mcp_servers.surge-xt]
command = "uvx"
args = ["surge-xt-mcp"]
Gemini CLI
gemini mcp add surge-xt uvx surge-xt-mcp
This writes .gemini/settings.json in the current project, and Gemini CLI asks you to trust the folder first. Add -s user before the name to install it for every project. By hand, add the standard block to ~/.gemini/settings.json.
Grok CLI
grok mcp add surge-xt uvx surge-xt-mcp
OpenCode
opencode mcp add surge-xt -- uvx surge-xt-mcp
This writes your global opencode.jsonc. By hand, the entry looks like this:
{
"$schema": "https://opencode.ai/config.json",
"mcp": {
"surge-xt": {
"type": "local",
"command": ["uvx", "surge-xt-mcp"]
}
}
}
Windsurf (Devin Desktop)
Open Customize → MCPs → Open MCP config file and add the standard block. Current builds keep it in ~/.config/devin/mcp_config.json (%APPDATA%\devin\mcp_config.json on Windows). Older Windsurf builds use ~/.codeium/windsurf/mcp_config.json.
Cline
Click the MCP Servers icon, open the Configure tab, choose Configure MCP Servers and add the standard block to cline_mcp_settings.json.
Zed
Add this to settings.json (Settings → AI → MCP Servers → Add Local Server opens the same entry). Zed uses a context_servers key.
{
"context_servers": {
"surge-xt": {
"command": "uvx",
"args": ["surge-xt-mcp"]
}
}
}
Goose
Add this under extensions in ~/.config/goose/config.yaml (%APPDATA%\Block\goose\config\config.yaml on Windows), or run goose configure and choose Add Extension → Command-line Extension. Goose calls the keys cmd and envs.
extensions:
surge-xt:
name: surge-xt
type: stdio
enabled: true
cmd: uvx
args: ["surge-xt-mcp"]
timeout: 300
Continue
Add this to ~/.continue/config.yaml. Continue lists servers and runs MCP tools in agent mode.
mcpServers:
- name: surge-xt
type: stdio
command: uvx
args:
- "surge-xt-mcp"
JetBrains AI Assistant and Junie
In AI Assistant, open Settings → Tools → AI Assistant → Model Context Protocol (MCP), choose Add and paste the standard block. For Junie, put the standard block in ~/.junie/mcp/mcp.json, or .junie/mcp/mcp.json in a project.
Kiro and Amazon Q Developer CLI
Add the standard block to ~/.kiro/settings/mcp.json, or .kiro/settings/mcp.json in a workspace. The Amazon Q Developer CLI is now the Kiro CLI and reads the same file.
LM Studio
In the Program tab choose Install → Edit mcp.json and add the standard block. Needs LM Studio 0.3.17 or later.
Warp
Open Settings → Agents → MCP servers, choose Add and paste the standard block.
Any other client
Register a stdio server whose command is uvx with the single argument surge-xt-mcp. A client that only speaks HTTP can use the shared server at http://127.0.0.1:8000/mcp.
Update
uvx reuses the version it first downloaded. To move to the newest release, run this once and restart your client:
uvx surge-xt-mcp@latest --version
Install once
To install the server as a permanent command instead of running it through uvx:
uv tool install surge-xt-mcp
Then use surge-xt-mcp as the command, with no arguments, in any block above. pip install surge-xt-mcp works too if you manage your own Python environment.
Example prompts
- "What is this patch doing? Then make it darker and wider."
- "Find me five warm pads from the third-party packs and play each one."
- "Design a plucky bell with delay, then route the mod wheel to the filter cutoff."
- "Add a spring reverb to scene A and show me its controls."
- "Play a slow four-bar progression in D minor with this patch."
- "Load a 19-tone equal temperament scale and play an ascending run."
- "Watch the synth and tell me which knobs I move."
Tools (51)
| Workflow | Tools |
|---|---|
| Check the connection and installed libraries | surge_status, surge_doctor |
| Design and apply a sound | design_sound, apply_recipe |
| Understand the current sound | describe_patch, get_parameter, list_modulations, get_modulation, list_effects, get_wavetable, get_tuning |
| Browse, load and save patches | list_patch_categories, list_patches, patch_info, load_patch, next_patch, random_patch, save_patch |
| Find controls | list_parameters (curated, offline), discover_parameters (live, searchable, paginated) |
| Edit controls and compare versions | set_parameter, set_parameter_option, set_filter, set_envelope, set_macro, capture_parameters |
| Effects, modulation and wavetables | set_effect, set_modulation, set_wavetable, cycle_wavetable |
| Tuning | list_tunings, load_tuning, set_tuning_folder, set_standard_tuning |
| Audition | play_note, play_chord, play_melody, play_frequency, stop_notes |
| Perform with controllers | send_midi_cc, pitch_bend, send_aftertouch |
| Hold and shape individual voices | start_note, set_note_expression, held_notes, release_note |
| Play a polyphonic score | play_performance, performance_status, stop_performance |
| Follow edits made in Surge XT or another controller | poll_osc_changes |
| Render a stereo WAV from a saved patch | render_preview |
Each tool carries a title and read-only, destructive and idempotent hints, so clients can label it and skip confirmation for the 20 tools that only read.
Prompts: sound_check, design_a_sound, explain_current_patch, find_a_patch. Resources: surge://guide, surge://parameters, surge://performance.
Good to know
- Values. Float controls take normalized values from 0 to 1, integer controls take raw indices and switches take 0 or 1. Every read returns Surge XT's display text, such as
900.00 Hzor700.0 ms. Unit ranges - Recipes.
design_soundsuggests a factory template asstart_patch. Load it first for a predictable result. Applied to another patch, a recipe keeps that patch's effects, routes and untouched controls. - Confirmation. Edits report
verifiedwhen Surge XT read the value back. Notes and MIDI controller messages have no receipt in OSC, so those tools reportdelivery: "sent". - Saving. Saving over an existing patch needs
overwrite=true. Omit the name to save under the patch's own name and category. - A/B comparison.
capture_parametersreturns steps you can pass back toapply_recipeto restore the earlier values. - Stopping.
stop_notesinterrupts any audition.immediate=truealso cuts the tails.
Expressive performance
Start two notes of the same pitch with start_note. Each result has its own note_id. Pass one ID to set_note_expression to bend that voice, pan it, change its volume or vary timbre and pressure. release_note accepts a release velocity.
play_performance plays overlapping voices on a beat grid. Times are in beats, and expression times count from the start of their note.
{
"bpm": 100,
"notes": [
{"note": "F#3", "duration": 2, "velocity": 94,
"expression": [{"at": 1, "parameter": "pitch", "value": 2}]},
{"at": 0.5, "note": "A3", "duration": 1.5, "release_velocity": 48}
]
}
For a longer score, pass background=true. The tool returns a performance ID at once. performance_status reports progress, and stop_performance releases only that score's voices.
Following the synth
To follow a patch loaded from the Surge XT window or another controller, call poll_osc_changes with watch_address="/patch" and prefix="/patch", then pass the returned cursor on the next call. Each event says whether it was pushed by the synth or found by reading the address back.
Configuration
Set these as environment variables in your client's server entry (most clients accept an env object next to command and args). .env.example lists them with comments.
| Variable | Default | Meaning |
|---|---|---|
SURGE_OSC_HOST |
127.0.0.1 |
Host running Surge XT |
SURGE_OSC_SEND_PORT |
53280 |
Surge XT OSC In port |
SURGE_OSC_RECV_PORT |
53281 |
Surge XT OSC Out port, where replies arrive |
SURGE_OSC_LISTEN_HOST |
127.0.0.1 |
Local IPv4 address that receives replies. For a synth on another machine, use this machine's LAN address |
SURGE_OSC_TIMEOUT |
2.0 |
Seconds to wait for a reply |
SURGE_PATCH_TIMEOUT |
15.0 |
Seconds allowed for patch loads, saves and library refreshes, up to 30 |
SURGE_DATA_DIR |
Platform default | Surge XT factory data folder, for portable or relocated installs |
SURGE_USER_PATCH_DIR |
Platform default | Surge XT user patch folder |
SURGE_PATCH_DIRS |
None | Extra patch folders, separated like PATH |
MCP_TRANSPORT |
stdio |
stdio or http (Streamable HTTP) |
MCP_HTTP_HOST |
127.0.0.1 |
HTTP bind address |
MCP_HTTP_PORT |
8000 |
HTTP port |
MCP_HTTP_PUBLIC_HOST |
None | Extra hostname accepted from an HTTP client or reverse proxy |
Command-line flags override the matching variables: --osc-host, --osc-send-port, --osc-recv-port and --transport. --version prints the version. --doctor prints the diagnosis as JSON and exits with status 1 when the OSC round trip fails.
Several clients at once
Every MCP client can start its own server. Surge XT sends its replies to one port, so the first server to start owns that port and passes a copy of each reply to the other servers on the same machine. When it exits, one of the others takes the port over. surge_status reports reply_port_mode as direct for the owner and shared for the rest.
A client on another machine, or one that only speaks HTTP, can use one shared server instead:
uvx surge-xt-mcp --transport http
Then point each client at http://127.0.0.1:8000/mcp as a Streamable HTTP server.
Troubleshooting
| Symptom | What to do |
|---|---|
No reply from Surge XT |
Open Surge XT and enable both OSC In and OSC Out in Menu → OSC Settings. The two ports must match the server's. Ask the assistant to run surge_doctor. |
Could not bind OSC reply port |
A program that does not share the port holds it. Servers from 0.2.1 on share it with each other, so update and restart any client that still runs an older one. For any other program, close it or pick another pair of ports. |
surge-xt-cli exits while notes play |
The command-line player in the 1.3.4 release runs OSC notes on two threads at once. The standalone application and the plug-ins do not. To run headless, build the player with the upstream fix: tests/build-surge-xt-cli.sh. |
| Ports refuse to open on Windows | Hyper-V and WSL can reserve the default ports. Pick a free pair such as 48000 and 48001 in Surge XT and pass --osc-send-port and --osc-recv-port. Details |
The client cannot find uvx |
Desktop apps do not always see your shell's PATH. Use the full path to uvx as the command. |
Tools report sent but you hear nothing |
Notes have no receipt in OSC. Check Surge XT's audio output, or the track's input monitoring in your DAW. |
legacy_text protocol in surge_status |
Surge XT 1.3.0 answers in an older format. Update to 1.3.4 for patch queries and modulation readback. |
Optional: render WAV files
render_preview renders notes from a saved patch to a stereo WAV without a running synth. It needs NumPy and the Surge XT Python bindings (surgepy), which are built from the Surge XT source and are not part of the standard installer. When they are missing, the tool explains how to enable it and the live tools keep working. Results include the sample rate, peak, RMS and a silence flag. An existing file is replaced only after a render succeeds.
How it works
MCP client (Claude, Cursor, VS Code, Codex, ...)
| MCP over stdio or Streamable HTTP
v
surge-xt-mcp (Python)
|-- patch library scan (.fxp files on disk, offline)
|-- recipe engine (words -> steps in real units)
|-- OSC client --UDP 53280--> Surge XT 1.3.4 (standalone or in a DAW)
|<-- replies and display values --UDP 53281--|
`-- optional surgepy engine -> WAV files
The server uses only Surge XT's documented OSC interface. OSC reference · Product brief · Delivery plan
Development
uv sync --locked --extra dev
uv run pytest
uv run ruff check src tests
uv run ruff format --check src tests
uv run mypy
The default suite needs no synth: it uses real UDP sockets and real MCP clients over both transports. Opt-in tests drive a disposable Surge XT instance through every tool, every parameter and every recipe family. Contributing · Verification results
Roadmap
- Move to version 2 of the MCP Python SDK.
- List the server in the MCP registry.
- Count PyPI installs in the downloads badge once the download statistics services list the package.
License
MIT. Surge XT itself is GPL-3.0-or-later software by the Surge Synth Team. This project communicates with it over OSC and redistributes no Surge XT code. It is not affiliated with the Surge Synth Team. Notice · Security
Metadata
Release files for surge-xt-mcp 0.2.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| surge_xt_mcp-0.2.1.tar.gz | 521.6 kB | Without provenance | Details for surge_xt_mcp-0.2.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| surge_xt_mcp-0.2.1-py3-none-any.whl | Python 3 | none | any | Details for surge_xt_mcp-0.2.1-py3-none-any.whl |
Total release size: 598.2 kB
Release files / surge_xt_mcp-0.2.1.tar.gz
| Download URL | surge_xt_mcp-0.2.1.tar.gz |
|---|---|
| Size | 521.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
bcebd5e91f4ae392dc421e275e5fb2edd24a8766c096dac410752ceee7fd369a
|
|
BLAKE2b-256 checksum How to use checksums |
90af66dc8ee85ace3bb367bd62ccb84fa2b6000e328f9af022a00f4e26c6057a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.13.10 {"installer":{"name":"uv","version":"0.13.10","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Release files / surge_xt_mcp-0.2.1-py3-none-any.whl
| Download URL | surge_xt_mcp-0.2.1-py3-none-any.whl |
|---|---|
| Size | 76.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3eb4015ee934cd53959a8cdf2bb7caa2df9ac8f3d60ca2908f751d54014b04d5
|
|
BLAKE2b-256 checksum How to use checksums |
ccc78a2c9c018e9a2b9995fe3df514ccc37414f99df183df4b040aa2740a5421
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.13.10 {"installer":{"name":"uv","version":"0.13.10","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Security for surge-xt-mcp 0.2.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.