FL Studio MCP
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
FL Studio MCP
Let Claude, or any MCP client, make music in FL Studio. It writes the notes, loads your installed plugins, sets their parameters, mixes, arranges, exports and changes settings, all in your running copy of FL Studio, using FL's own scripting API and windows.

Recorded in FL Studio 2025: one request, an empty project, around thirty tool calls, a finished loop. Every caption is a real tool call. π§ Listen to the result (MP3, 34 s)
Contents
Related MCP server: fl-mcp-2026
A session, step by step
The request:
Make a 4-bar lo-fi loop at 85 BPM with Rhodes-style chords, a simple bassline and swung drums. Put some reverb on the keys, lay it out in the playlist and export an MP3.
These are the actual tool calls that made the demo in FL Studio 2025, with FL's real answers (trimmed where marked ...; file paths shortened).
1. Set up the project
fl_song_settings(bpm=85) # β {"bpm": 85.0, "beats_per_bar": 4}
fl_add_instrument("FL Keys") # β {"channel": 1, "name": "FL Keys", "plugin": "FL Keys"}
fl_add_instrument("Transistor Bass") # β {"channel": 2, "name": "Transistor Bass", ...}
fl_add_instrument("FPC") # β {"channel": 3, "name": "FPC", "plugin": "FPC"}
fl_api([{"fn": "plugins.nextPreset", "args": [3, -1, True]},
{"fn": "plugins.getName", "args": [3, -1, "midi.FPN_Preset", 0, True]}])
# β [{"ok": null}, {"ok": "Breakbeat"}] (FPC drum kit)
fl_channel(1, name="Keys", color="#9B7BE0", mixer_track=1) # same for Bass β 2, Drums β 3
fl_mixer_track(1, name="Keys", color="#9B7BE0")
2. Write the parts
Notes go straight into each channel's piano roll. Keys can be names or MIDI numbers, and the tool answers with every note now in the pattern, so the assistant can check its work.
fl_notes(channel=1, pattern=1, clear=True, add=[
{"key": "F4", "start": 0, "length": 3.8, "velocity": 92},
{"key": "A4", "start": 0.03, "length": 3.77, "velocity": 86},
... # 16 notes: Fmaj7 | Em7 | Dm7 | Cmaj7, lightly strummed
])
# β {"ppq": 96, "time_signature": [4, 4], "channel": 1, "pattern": 1,
# "notes": [{"key": 53, "start": 0.0, "length": 3.802, "velocity": 92, ...}, ... 16 notes]}
fl_notes(channel=2, pattern=1, clear=True, add=[...]) # 12 bass notes: root, pickup, fifth
fl_notes(channel=3, pattern=1, clear=True, add=[...]) # 52 drum hits: kick 36, snare 38,
# closed hat 42 with swing and soft offbeats
3. Effects and mix
fl_plugin_params returns each parameter with the value FL shows, so the assistant can see what a number means before it commits to it. The first try at the reverb's decay (0.45) came back as 9.1sec, so the value came down to 0.12:
fl_add_effect("Fruity Reeverb 2", mixer_track=1)
# β {"mixer_track": 1, "slot": 0, "plugin": "Fruity Reeverb 2"}
fl_plugin_params(mixer_track=1, slot=0)
# β {"plugin": "Fruity Reeverb 2", "param_count": 15, "params": [
# {"index": 0, "name": "Low cut", "value": 0.0188, "text": "75Hz"},
# {"index": 1, "name": "High cut", "value": 0.162, "text": "4.0kHz"}, ...]}
fl_set_plugin_params({"Room size": 0.75, "Decay time": 0.12, "Wet level": 0.32,
"High cut": 0.35}, mixer_track=1, slot=0)
# β {"3": "75", "5": "2.5sec", "12": "40%", "1": "8.1kHz"}
fl_add_effect("Fruity Limiter", mixer_track=0)
fl_mixer_track(1, volume=0.72, pan=-0.1)
fl_mixer_track(2, volume=0.70)
fl_mixer_track(3, volume=0.78, stereo=0.2)
4. Arrange and export
The playlist has no API for placing pattern clips, so the assistant takes a screenshot and clicks, the way a person would. The audio clip is a WAV bounce of the loop, dropped back in.
fl_export("lofi_loop.wav", mode="pattern") # β {"bytes": 1992468, "mode": "pattern"}
fl_screenshot() # find track 1, bar 1 and bar 5
fl_click(190, 114); fl_click(424, 114) # paint two clips of the pattern
fl_drop_files(["lofi_loop.wav"], x=655, y=146) # audio clip on track 2 at bar 9
fl_api([{"fn": "playlist.setTrackName", "args": [1, "Beat (pattern)"]},
{"fn": "playlist.setTrackName", "args": [2, "Bounce (audio)"]}])
fl_export("lofi-demo.mp3", format="mp3", mode="song")
# β {"file": "...\\lofi-demo.mp3", "bytes": 822601, "mode": "song"}
What the assistant cannot do is hear. It checks its work by reading notes back, reading parameter values as FL displays them, and looking at screenshots. The ears in the loop are yours: ask for changes the way you would ask a producer ("darker chords", "less reverb", "push the hats back").
What it can do
You want to⦠| Tool |
Write, read or delete notes in the piano roll |
|
Program drums in the step sequencer |
|
Set the BPM and time signature |
|
Load an installed instrument (Serum 2, Vital, Sytrus, FLEXβ¦) |
|
Load an installed effect onto a mixer slot |
|
Read and set plugin parameters |
|
Set mixer faders, pan, stereo, mute, solo, arm, names, colours, routing |
|
Set channel volume, pan, pitch, mute, solo, names, colours, mixer routing |
|
Play, stop, record, switch song/pattern mode, metronome, jump to a bar |
|
Put audio clips in the playlist (or samples in the channel rack) |
|
Export the song or a pattern to WAV, MP3 or MIDI |
|
Save, save as, open projects and files |
|
Call anything in FL's scripting API |
|
Use any menu, dialog, tool or setting a person can |
|
Quick start
Clone this repository and run the installer in PowerShell:
git clone https://github.com/Pabsetchak/fl-studio-mcp.gitcd fl-studio-mcppowershell -ExecutionPolicy Bypass -File .\install.ps1In FL Studio, open Options > MIDI settings, enable the loopMIDI input and set its controller type to FL Studio MCP Controller.
Restart Claude, open a piano roll in FL Studio and run Tools > Scripting > ComposeWithLLM once.
Ask for something, for example the request in the session above.
The full steps are in Installation.
Requirements
Windows with FL Studio 2024 or 2025 (tested on FL Studio 2025 Producer Edition, scripting API v38). The desktop part of the server uses Windows APIs, so macOS is not supported.
loopMIDI, a free virtual MIDI port.
uv (the installer gets it for you).
An MCP client such as Claude Desktop or Claude Code.
Installation
1. Run the installer
From PowerShell in the cloned folder:
powershell -ExecutionPolicy Bypass -File .\install.ps1It installs uv and the Python dependencies, copies the two FL Studio scripts into place and adds the server to Claude Desktop, Claude Code or both (it asks) as fl-studio. If you prefer to do it by hand:
Copy
fl_controller\device_FLStudioMCP.pytoDocuments\Image-Line\FL Studio\Settings\Hardware\FLStudioMCP\.Copy
scripts\ComposeWithLLM.pyscripttoDocuments\Image-Line\FL Studio\Settings\Piano roll scripts\.Add this to your MCP client's configuration:
"fl-studio": { "command": "uv", "args": ["run", "--directory", "C:\\path\\to\\fl-studio-mcp", "fl-studio-mcp"] }
2. Create the loopMIDI port
Open loopMIDI, type a port name (the default "loopMIDI Port" is fine) and click +. loopMIDI must be running whenever you use the server. If your port's name does not contain "loopMIDI", set the environment variable FL_MCP_MIDI_PORT to part of its name.
3. Set up FL Studio
Start FL Studio and open Options > MIDI settings (F10, then the MIDI tab).
Under Input, click your loopMIDI port so it is enabled (highlighted).
Set its Controller type to FL Studio MCP Controller.
Restart your MCP client so it loads the server.
Before each session
Run the piano roll script once each time FL Studio starts: open any piano roll and choose Tools > Scripting > ComposeWithLLM. The server then reruns it with Ctrl+Alt+Y ("run last script"), which only works after it has been run once by hand. If you skip this, fl_notes reports exactly this step as the fix.
The server really moves your mouse and presses keys. Loading effects, dropping audio, exporting, saving as, changing the time signature and every fl_click/fl_key tool use FL Studio's own windows. Do not touch the mouse or keyboard while the assistant is working, and keep FL Studio's window on screen.
Tools
Start with fl_status: it lists the tempo, transport, patterns, every channel (index, name, plugin, mixer track) and the mixer tracks in use with their effects.
Composition
fl_notes(channel, pattern, add, clear, delete_from, delete_to, delete_keys)writes or reads notes in a channel's piano roll and returns every note in it.addtakes notes like{"key": "C5", "start": 0, "length": 1, "velocity": 100}, with optionalpan,slide,porta,colorandmuted. With nothing to change it just reads.fl_steps(channel, steps, pattern, clear)turns on step-sequencer steps (0 is the first 16th).fl_song_settings(bpm, numerator, denominator)sets the tempo and the time signature.fl_transport(action, bar):play,pause,stop,record,song_mode,pattern_mode,metronome_on,metronome_off, orgotoa bar.
Plugins
fl_installed_plugins(kind, search)lists the plugins in FL Studio's plugin database. If a plugin you own is missing, run a plugin scan in FL's Plugin Manager.fl_add_instrument(name)loads an instrument into a new channel and returns its index. Names match exactly first, then by substring; Fruity, then VST3, then CLAP, then VST versions are preferred.fl_add_effect(name, mixer_track, slot)loads an effect into a mixer track, on the first free slot unless you give one.fl_plugin_params(channel | mixer_track + slot, search, limit)lists parameters with their index, name, 0β1 value and display text.fl_set_plugin_params(values, channel | mixer_track + slot)sets parameters by name or index, for example{"Cutoff": 0.4, "12": 1}, and returns the display text of each.
Mixing
fl_mixer_track(track, volume, pan, stereo, mute, solo, arm, name, color, routes)sets a mixer track.routesadds or removes sends, as in{"5": true}.fl_channel(channel, volume, pan, pitch_cents, mute, solo, name, color, mixer_track)sets a channel and can route it to a mixer track.
Files
fl_drop_files(paths, x, y)drags files from disk onto FL Studio at a point in the latest screenshot, exactly like dropping them from Explorer. Audio on a playlist track makes an audio clip at that bar; on the channel rack it makes a new sampler channel.fl_open(path)opens a file as if double-clicked: a.flpproject, a.fstplugin preset, or a.midto import.fl_save(path)saves the project, or saves it as a new.flp. Save as never overwrites an existing file.fl_export(path, format, mode, timeout)renders the song (mode="song") or the current pattern ("pattern") towav,mp3ormid, then waits until the file is written.
Everything else
fl_api(calls, stop_on_error)runs any functions of FL's scripting API (transport,mixer,channels,patterns,playlist,arrangement,plugins,ui,general,device) in one round trip, for example[{"fn": "patterns.setPatternName", "args": [1, "Verse"]}]. A string such as"midi.FPT_Metronome"is replaced by that constant.fl_api_docs(name, search)looks up that API: a module's functions, one function's documentation, ormidiconstants.fl_screenshot()shows the FL Studio window.fl_windows()gives where the playlist, mixer, channel rack, piano roll, plugin windows and dialogs are.fl_click,fl_drag,fl_scroll,fl_key,fl_typeuse the mouse and keyboard at screenshot coordinates. Together with FL's shortcuts (F10 settings, F11 project info, F8 plugin picker, Alt+F8 browser, Ctrl+Z undo), they reach every menu, dialog and setting.
Conventions
Channels use the channel rack's global index from 0, as
fl_statuslists them, even when a channel filter group hides some.Mixer track 0 is Master; inserts are 1 to 125. Effect slots are 0 to 9.
Patterns and playlist tracks start at 1.
Notes:
keyis a MIDI number or a name in FL's naming, where C5 = 60. Times and lengths are in beats (quarter notes). Velocity is 0β127.Levels: volumes and plugin parameters are 0β1. Mixer 0.8 is 0 dB; a new channel sits at 0.78. Pan and stereo are β1 to 1.
More things to ask
"Make a 4-bar trap beat at 140 BPM: 808 on Serum 2, hats in the step sequencer, and a dark bell melody."
"Put Fruity Reeverb 2 on the lead's mixer track and make it wetter."
"Drop
C:\Samples\vocal.wavon playlist track 3 at bar 9.""Switch the song to 6/8 and export it as an MP3 to my Desktop."
"Open the audio settings and raise the buffer length."
Limitations
Some tools click FL's windows. Changing the time signature (in the settings window) and loading effects (onto a mixer slot) use positions measured on FL Studio 2025's default layout at 100% Windows scaling. If your layout or FL version differs, these tools report an error, and the assistant can still do the step with screenshots and clicks.
Export and Save as use FL's shortcuts (Ctrl+R, Ctrl+Shift+R, Ctrl+Shift+M, Ctrl+Shift+S). If another app has taken one of them, that tool reports that FL did not open its dialog.
Export formats are WAV, MP3 and MIDI. MIDI export follows FL Studio's own rules for what goes into the
.midfile.The piano roll script must be run once by hand each time FL Studio starts (see Before each session).
The mouse and keyboard move during UI work, and FL Studio comes to the front.
Placing clips needs a screenshot. FL's API cannot place playlist clips, so the assistant finds the track and bar in a screenshot and clicks or drops there.
Plugin parameters are what each plugin exposes to FL Studio's automation.
Windows only.
Troubleshooting
"No loopMIDI port found." Start loopMIDI and make sure it has a port. If the port has another name, set FL_MCP_MIDI_PORT to part of it.
"FL Studio did not answer." Check that FL Studio is open, that the loopMIDI port is enabled under Options > MIDI settings > Input, and that its controller type is "FL Studio MCP Controller". View > Script output shows "FL Studio MCP bridge ready" when the script has loaded.
fl_notes says the piano roll script did not answer. Open a piano roll and run Tools > Scripting > ComposeWithLLM once.
"FL Studio did not open its save dialog." Another app may use that shortcut. Close it, or export from FL's File menu by hand.
A UI tool clicked the wrong place. Close any extra dialog, take a screenshot to see FL's state, and try again. Detached or resized windows can move the mixer slots that the tools click.
The left mouse button seems stuck after a drop. Click once anywhere. The drop releases the button even when it fails, but an interrupted session can leave it down.
How it works
MCP client βββΆ FastMCP server
ββ bridge.run() JSON command file + MIDI note 127 on loopMIDI
β ββΆ FL Studio MCP Controller script (any API call)
ββ bridge.piano_roll() JSON request file + Ctrl+Alt+Y
β ββΆ ComposeWithLLM piano roll script (notes)
ββ desktop FL's command line, keyboard, mouse and drag-and-drop
(plugins, audio clips, export, dialogs, settings)API calls. The server writes
mcp_command.jsonwith an id and a list of calls, then sends MIDI note 127 on the loopMIDI port. The controller script runs every call through FL's scripting API and writesmcp_response.json. FL's Python cannot delete files, so the server removes the command once it is answered and the id stops a command from running twice.Notes. FL only lets piano roll scripts edit notes. The server writes
mcp_request.json, focuses the piano roll and presses Ctrl+Alt+Y; ComposeWithLLM applies the edits and answers with every note in the pattern.Desktop. For what no API can do, the server uses FL Studio like a person: it starts
FL64.exewith a plugin preset to add an instrument, drags plugin presets and audio files onto the mixer and playlist with real Windows drag-and-drop, presses FL's shortcuts for export and Save as, and clicks in the settings window.
Development
uv syncuv run pytestuv run ruff check src tests fl_controllerThe tests run the FL Studio controller script against the FL Studio API stubs and send commands to it through the real bridge, so they need no FL Studio.
fl-studio-mcp/
βββ fl_controller/device_FLStudioMCP.py # runs inside FL Studio: generic API bridge
βββ scripts/ComposeWithLLM.pyscript # runs inside FL Studio: piano roll edits
βββ src/fl_studio_mcp/
β βββ server.py # the MCP tools
β βββ bridge.py # file + MIDI round trips to both FL scripts
β βββ desktop.py # windows, screenshots, mouse, keys, drag-and-drop
βββ tests/test_bridge.py
βββ assets/ # the demo session's GIF, screenshots and MP3
βββ install.ps1Issues and pull requests are welcome.
Credits
This project started from karl-andres/fl-studio-mcp (MIT), which first connected an MCP server to FL Studio's MIDI scripting. It has since been rebuilt around a generic API bridge, plugin loading, desktop automation and export.
calvinw/fl-studio-mcp for the piano roll script approach.
FL Studio API Stubs for the API documentation.
Image-Line for FL Studio. This project is not affiliated with Image-Line.
License
MIT. See LICENSE.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelogβ¦
This server cannot be deployed
Maintenance
Related MCP Connectors
Generate AI music via the Lacuna Music API from MCP clients like Claude Desktop & Code.
Read and edit DAW projects as an agent, save native Logic projects, convert projects between DAWs
Create, co-edit, analyze, publish, and export collaborative step-sequencer sessions through MCP.
Design music, generate songs and lyrics, edit audio and arrange Studio projects.
Related MCP Servers
- AlicenseNot gradedqualityBmaintenanceEnables agents to control FL Studio through an MCP interface, including running Python inside FL, capturing screenshots, sending clicks and keystrokes, writing multi-channel piano roll notes, and building full arrangements from a song spec without moving the cursor.4MIT
- AlicenseNot gradedqualityCmaintenanceEnables Claude Desktop to drive FL Studio 2025 and 2026 through natural language, diagnosing and repairing mixes, configuring plugins, writing notes and chords in any scale, exporting arrangements to MIDI, and analyzing audio for tempo, key, and melody.MIT
- AlicenseNot gradedqualityBmaintenanceFL Studio MCP server: Claude, Cursor or VS Code makes music in your own copy of FL Studio.4MIT
- AlicenseNot gradedqualityCmaintenanceEnables AI assistants to control a running FL Studio project β transport, mixer routing and levels, channel rack, plugins, patterns, step sequencer, and piano roll β through a virtual MIDI trigger plus JSON command channel, with optional Windows UI automation and offline audio analysis of bounces. Also exposes raw access to the FL scripting API for undo history, markers, and device and project info.MIT