How to Configure the revit-mcp Server for Claude Desktop and Other MCP Clients

Configure the revit-mcp server by building the project with npm run build and adding a JSON entry to claude_desktop_config.json that points node to the compiled build/index.js file.

The revit-mcp repository implements a Model Context Protocol (MCP) server that exposes Revit-specific tools to AI assistants. To use these capabilities in Claude Desktop or other MCP-compatible clients, you must configure the client to launch the server process and communicate over standard input/output (STDIO).

Understanding the revit-mcp Server Architecture

The server bootstrap process in src/index.ts creates an McpServer instance and establishes a StdioServerTransport connection. This design allows any MCP client that supports STDIO transport to discover and invoke the server's tools.

Tool registration occurs dynamically through src/tools/register.ts, which scans the src/tools directory and registers every available tool—including get_current_view_info, create_point_based_element, and search_modules—with the central server instance.

Because the server communicates via STDIO, the client configuration only needs to specify how to start the server process and which script to execute.

Prerequisites and Installation

Before configuring your MCP client, build the server from source:


# Clone the repository

git clone https://github.com/mcp-servers-for-revit/revit-mcp.git
cd revit-mcp

# Install dependencies (requires Node.js 18+)

npm install

# Compile TypeScript to JavaScript

npm run build

The build process generates build/index.js, which serves as the server entry point. Note the absolute path to this file, as you will need it for the client configuration.

Configuring Claude Desktop for revit-mcp

Claude Desktop reads server configurations from a JSON file named claude_desktop_config.json. Adding the revit-mcp server entry enables the hammer icon in the interface, indicating an active MCP connection.

Locating the Configuration File

Find the configuration file in your system's Claude Desktop settings directory:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json

Create the file if it does not exist.

Adding the revit-mcp Server Entry

Insert the following JSON structure into the mcpServers object, replacing <path-to-project> with the absolute path to your revit-mcp installation:

{
  "mcpServers": {
    "revit-mcp": {
      "command": "node",
      "args": ["<path-to-project>/build/index.js"]
    }
  }
}

On Windows, use escaped backslashes (\\) or forward slashes (/) to avoid JSON parsing errors:

{
  "mcpServers": {
    "revit-mcp": {
      "command": "node",
      "args": ["C:\\Users\\alice\\projects\\revit-mcp\\build\\index.js"]
    }
  }
}

Verifying the Connection

Save the configuration file and restart Claude Desktop. Look for the hammer icon in the bottom-left corner of the interface. Clicking this icon displays the list of available Revit tools, confirming that the STDIO transport is active and the server has registered its tools successfully.

Configuring Other MCP Clients

Any MCP-compatible client that supports STDIO transport—such as Cline, Continue, or custom scripts—uses the same configuration pattern. Copy the mcpServers JSON entry from the Claude Desktop example into your client's equivalent configuration file, adjusting the path to build/index.js as needed.

For clients that support environment variables, you may also specify the path dynamically:

{
  "mcpServers": {
    "revit-mcp": {
      "command": "node",
      "args": ["${REVIT_MCP_PATH}/build/index.js"]
    }
  }
}

Troubleshooting Common Configuration Issues

  • "Command not found" errors: Ensure Node.js is installed and available in your system PATH. The command field must reference the Node.js executable (node on most systems, node.exe on Windows if needed).
  • Path resolution failures: Verify that the path in args points to the compiled build/index.js file, not the TypeScript source. Re-run npm run build if the file is missing.
  • STDIO transport timeouts: Confirm that no other process is occupying the STDIO streams. The server logs Revit MCP Server start success to stderr on successful startup; check your client logs for this message.
  • Tool registration failures: If the hammer icon appears but tools are missing, check that the src/tools directory contains the expected .ts files and that src/tools/register.ts executed without errors during startup.

Summary

  • The revit-mcp server communicates via STDIO transport, requiring only a command and arguments to launch.
  • Build the project with npm install and npm run build to generate build/index.js.
  • Configure Claude Desktop by adding a revit-mcp entry to claude_desktop_config.json with command: "node" and args pointing to the built file.
  • Restart the client and verify the connection via the hammer icon and available Revit tools.

Frequently Asked Questions

What is the exact JSON structure needed for Claude Desktop configuration?

You must add a revit-mcp object under the mcpServers key in claude_desktop_config.json. The structure requires a command field set to "node" and an args array containing the absolute path to build/index.js. This tells Claude Desktop how to spawn the server process and establish the STDIO connection.

Can I use revit-mcp with clients other than Claude Desktop?

Yes. Any MCP client that supports STDIO transport—including Cline, Continue, and custom Node.js scripts—can connect to revit-mcp. Copy the same mcpServers configuration into your client's settings file, ensuring the path to build/index.js is correct for your file system. The server automatically registers all available tools regardless of which client initiates the connection.

Why does the server fail to start with "module not found" errors?

This error typically occurs when you attempt to run the TypeScript source directly instead of the compiled JavaScript, or when dependencies are missing. Run npm install to fetch dependencies and npm run build to generate the build/index.js file. Ensure your configuration's args array points to this compiled file, not src/index.ts.

Have a question about this repo?

These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:

Share the following with your agent to get started:
curl -s "https://instagit.com/install.md"

Works with
Claude Codex Cursor VS Code OpenClaw Any MCP Client

Maintain an open-source project? Get it listed too →