home / mcp / foundry vtt mcp bridge mcp server
Connect Foundry VTT to Claude Desktop via MCP to manage campaigns with AI-powered insights across D&D 5e and PF2E content.
Configuration
View docs{
"mcpServers": {
"adambdooley-foundry-vtt-mcp": {
"command": "node",
"args": [
"path/to/foundry-vtt-mcp/packages/mcp-server/dist/index.js"
],
"env": {
"FOUNDRY_HOST": "localhost",
"FOUNDRY_PORT": "31415"
}
}
}
}You can connect Foundry VTT to Claude Desktop using the MCP Bridge to manage campaigns with AI-powered insights. It enables natural language interactions with your game data, including quest creation, character management, compendium searches, content generation, and dynamic map creation, all while keeping control over what Claude can access and modify.
You interact with the MCP Bridge through Claude Desktop. Start Foundry VTT with your world loaded, then open Claude Desktop to chat with Claude about your World in Foundry. You can ask to create quests from your world lore, query character stats, search your compendium with natural language, generate actors or quest journals, inspect the current scene data, coordinate dice rolls, manage multi-part campaigns, and generate battlemaps via the ComfyUI backend. The GM-only design ensures that only Game Master users have access to these features.
Prerequisites you need before installation are: Foundry VTT v13, Claude Desktop with MCP support, and Windows for the automated installer or Node.js 18+ for manual install.
Option 1: Windows Installers guide the automated setup, including the MCP server with the bundled Node.js runtime and optional integration with the Foundry module and ComfyUI Map Generation.
Option 2: Mac Installer provides a native installer to perform the same setup steps as the Windows installer.
Option 3: Manual installation walks you through installing the Foundry module, installing and building the MCP server, and configuring Claude Desktop to connect to the MCP server.
Step-by-step manual installation commands and configuration items are shown in the following sections. Execute commands exactly as written to ensure the MCP server and Claude Desktop can communicate with Foundry VTT.
Install the Foundry Module: Open Foundry VTT v13 and choose Install Module from the Add-ons menu. In the bottom window, add the Manifest URL and install. Then enable the Foundry MCP Bridge module in Module Management. Avoid renaming the module directory or ID to prevent routing issues.
# Clone repository
git clone https://github.com/adambdooley/foundry-vtt-mcp.git
cd foundry-vtt-mcp
# Install dependencies and build
npm install
npm run build
# The following command is used to start the MCP server through Claude Desktop configuration.
# See the Claude Desktop configuration block for exact setup. The MCP server is launched by Node.js running the built file.Add an MCP server configuration so Claude Desktop can start and connect to the MCP server. The configuration uses Node.js to run the MCP server script and passes connection details via environment variables.
{
"mcpServers": {
"foundry_mcp": {
"command": "node",
"args": ["path/to/foundry-vtt-mcp/packages/mcp-server/dist/index.js"],
"env": {
"FOUNDRY_HOST": "localhost",
"FOUNDRY_PORT": "31415"
}
}
}
}Launching Claude Desktop with the configured MCP server automatically starts the MCP server. Ensure Foundry VTT is running your world when you begin chatting with Claude to access live data.
1. Start Foundry VTT and load your world. 2. Open Claude Desktop. 3. Begin a chat about your currently loaded Foundry World to explore AI-assisted management.
Ask Claude to show your character stats, search for encounters, create quests, roll dice for a character, or generate a map. These interactions leverage the MCP Bridge to work with Foundry VTT data in real time.
The MCP Bridge is designed for Game Master users. You can configure permissions to restrict Claude’s access to world content. Use WebRTC for remote connections or WebSocket for local connections as needed, and adjust the connection check frequency to balance responsiveness with network load.
Access character stats, abilities, inventory, and detailed entity information.
Move, update, delete tokens and manage status conditions.
Filter search results by CR, type, abilities, and more for quicker access.
Generate actors, NPCs, and quest journals from prompts.
Track multi-part quests and display progress dashboards.
Send dice roll requests to players from Claude.
Generate battlemaps from prompts and integrate with Foundry.
WebRTC and WebSocket connectivity between Claude Desktop, MCP server, and Foundry.
Restrict MCP Bridge features to Game Master users.
Manage player permissions for characters and tokens.