Roblox MCP Server

Roblox MCP Server

Enables AI assistants to interact with running Roblox game instances by inspecting the game hierarchy, reading client-side scripts, and executing Lua code directly within the Roblox client through a WebSocket bridge.

Category
Visit Server

README

Roblox MCP Server

A Model Context Protocol (MCP) server that acts as a bridge between AI assistants (like Claude/Gemini in IDEs) and a running Roblox instance. This allows the AI to inspect the game hierarchy, read scripts, and execute code directly within the Roblox client.

Architecture

graph LR
    IDE["AI / IDE"] <-->|"MCP Protocol (Stdio)"| MCPServer["MCP Server (Node.js)"]
    MCPServer <-->|"WebSocket (ws://localhost:3000)"| Roblox["Roblox Client"]
    subgraph Roblox Client
        Bridge["Bridge.lua"]
        Game["Game Engine"]
    end
    Bridge <--> Game

The system consists of two parts:

  1. MCP Server (src/): A Node.js application that implements the MCP specification. It hosts a WebSocket server to communicate with Roblox.
  2. Roblox Bridge (roblox/Bridge.lua): A Lua script that runs inside a Roblox executor. It connects to the MCP server via WebSocket and executes commands.

Prerequisites

  • Node.js: v18 or higher.
  • Roblox Executor: A Roblox script executor that supports:
    • WebSocket.connect (or compatible WebSocket library).
    • getgenv() (optional, for safe environment access).
    • decompile (optional, for reading local scripts).
  • npm or yarn.

Installation

  1. Clone the repository.
  2. Install dependencies:
    npm install
    

Usage

1. Start the MCP Server

You can run the server in development mode or build it for production.

Development:

# Compile and run
npm run build && npm start

The server will start listening on stdio for MCP connections and ws://localhost:3000 for the Roblox bridge.

2. Inject the Roblox Bridge

  1. Open your Roblox Executor.
  2. Open roblox/Bridge.lua.
  3. Execute the script in the desired Roblox game instance.
  4. Check the executor console (F9) for a connection message: [MCP-Bridge] Connected!.

Available Tools

The MCP server exposes the following tools to the AI:

list_children

Lists the children of a specific instance.

  • Arguments: path (string, e.g., "game.Workspace")
  • Returns: list of { name, className, path }

get_properties

Retrieves the properties of a specific instance.

  • Arguments: path (string), properties (array of strings, optional)
  • Returns: Map of property names to values.

read_script

Reads the source code of a script.

  • Arguments: path (string)
  • Returns: Source code string.
  • Notes:
    • Works for LocalScript and ModuleScript (client-side).
    • Cannot read server-side Script source due to Roblox replication security (returns empty/error).

run_script

Executes arbitrary Lua code in the context of the bridge script.

  • Arguments: code (string)
  • Returns: Array of return values converted to strings.

Troubleshooting

  • Server Code Access: You cannot read server scripts from the client. This is a Roblox engine limitation, not a bug.
  • Connection Failed: Ensure port 3000 is free and the executor supports WebSockets (most modern ones do).
  • Executor Compatibility: If WebSocket is not defined, check your executor's documentation. You may need a polyfill.

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured