About roblox-studio-mcp
roblox-studio-mcp is a skill reference for using Roblox Studio’s MCP tools to run Luau, inspect and change the datamodel, test interactions, and create or add assets. It is intended for Roblox developers working in a live Studio session, with practical guidance on connection issues and tool-specific constraints.
Key features
- 01Run Luau in Studio
- 02Inspect and search the datamodel
- 03Read and search scripts
- 04Simulate mouse and keyboard input
- 05Capture Studio screenshots
- 06Generate and insert assets
Use cases
- 01Test Luau against a live place
- 02Check whether Rojo synced script changes
- 03Inspect game objects and runtime output
- 04Add Creator Store or generated assets
MCP support
Documents Roblox Studio’s MCP server tools and connection setup. Studio connects to an MCP hub and exposes tools for MCP clients.
Install
Copy the command and run it in a terminal.
npx skills add https:/ / github.com/ flatbedj/ roblox-skills --skill roblox-studio-mcpAfter installing, type/roblox-studio-mcpin Claude Code to confirm it loaded.
Details
From the project READMERoblox Studio MCP: remote-controlling Studio
The Studio MCP lets you run code inside a live Studio, inspect/modify the datamodel, screenshot, and generate content. This is the toolbox reference; for the disk→Rojo→test dev LOOP see the roblox-studio-workflow skill.
Connecting (and fixing a dead link)
- Studio dials OUT to the MCP hub and registers its tools. If Studio never connects, the MCP answers with 0 tools — ToolSearch/
mcp__Roblox_Studio__*find nothing. - Enable it in Studio: Assistant panel → Assistant Settings → "Enable Studio as MCP server". A green indicator under "Manage MCP Servers" = connected. Docs: create.roblox.com/docs/studio/mcp
- Dead-link fixes (in order): (1) toggle "Enable Studio as MCP server" off/on while a Codex session is running; (2) restart Studio after saving that setting; (3) an already-open Codex session may still hold the empty tool list — reconnect via
/mcpor start a fresh session. A Studio that auto-updated & relaunched before the MCP existed is the classic "enabled but not connected" case. - The MCP link can silently drop mid-session (the server disconnects) — after that the tools are gone until Studio reconnects. If tool calls start failing, check whether the link dropped before assuming a code problem.
Core tools (verified, used constantly)
execute_luau— run Luau in Studio. Requiresdatamodel_type:Edit|Server|Client. Runs in a SEPARATE Lua VM: the DataModel is shared (Instances, PlayerGui, Workspace, Net remotes), butrequire()module state is NOT — you get a fresh copy, so you can't read/mutate a live module's singletons.FireAllClientsonly works fromServer. Pure functions can be unit-tested with synthetic inputs here.start_stop_play—is_startbool (true=play, false=stop). Pair with the Rojo sync wait (see workflow skill) so you don't test stale code.get_console_output— read the output/errors. ALWAYS check after a boot for silent failures (e.g. "Out of local registers", a stuckWaitForChild, a service error).screen_capture— needs acapture_id. Artifacts to know: a freecam/scripted camera can leave ScreenGuis hidden, and distant SurfaceGui close-ups render blank — those are capture bugs, not game bugs (cross-check via instance queries). Coords for clicking are GUI AbsolutePosition space, not screenshot pixels — readAbsolutePosition + AbsoluteSize/2first.user_mouse_input/user_keyboard_input— simulate input. Both also requiredatamodel_type(not obvious from the schema).user_mouse_inputsupports aninstance_pathform to click a GUI object without coords. Keyboard fails with "CoreGUI has keyboard focus" when a core UI (chat, menu) owns focus. Note:VirtualInputManager:SendMouseButtonEventinsideexecute_luauFAILS ("lacking capability") — use these MCP input tools instead.inspect_instance/search_game_tree— inspect/find instances in the datamodel.script_read/script_grep/script_search— read/search the SCRIPTS currently in the datamodel. Great for confirming Rojo actually synced your latest edit:script_grepfor a new comment string before you trust a playtest.
Content-generation & asset tools (mostly UNTRIED here — explore, verify behavior)
generate_mesh— AI-generate a MeshPart from a prompt.generate_material— AI material/SurfaceAppearance.generate_procedural_model— a whole procedural model. Likely async → pair withwait_job_finished. Great for props/terrain/first-pass models; not yet exercised — validate quality + how the result lands in the datamodel.insert_asset(takes an assetId) — insert a Creator-Store asset.search_asset— searches the Creator Store only (Models/Images/Decals/etc.), NOT the avatar Marketplace (clothing/hair need the catalog Web API — seeroblox-avatar-appearance).upload_image/store_image— upload local PNGs →rbxassetid://.upload_imagetakesimagePathsand needs http/https URLs (local paths fail): serve a folder over localhost (python3 -m http.server 8777), passhttp://localhost:8777/foo.png, get back the id; kill the server (pkill -f "http.server 8777") when done. Byte-identical images dedup to the SAME id (re-uploading is safe). Batches fine (many at once).http_get— fetch a URL from Studio.character_navigation— move/navigate the player character (untried; useful for walking to a spot before a screenshot or proximity interaction).get_studio_state/list_roblox_studios/set_active_studio— multi-Studio awareness; point the tools at a specific open Studio when more than one is running.multi_edit— edits scripts IN the datamodel. Avoid for disk-authored (Rojo) scripts — it causes drift/duplicate instances (author those on disk; seeroblox-studio-workflow). Reserve for scripts that live only in the datamodel.
Golden rules
datamodel_typeis required onexecute_luauand the input tools — pickServerfor server APIs (DataStore, MessagingService, FireAllClients, LoadAsset),Clientfor PlayerGui/local checks,Editfor pre-play datamodel/property changes.- Set place properties / geometry in
Editmode so they persist (they need a place SAVE to be permanent); code belongs on disk via Rojo, not the MCP. - Verify via observable side-effects on Instances, never a live module's internal fields (cross-VM). See the testing strategy in
roblox-studio-workflow. - If tools vanish mid-task, suspect a dropped link (above) before a code bug.