Setting Up MCP Servers in claude cowork: A Complete Guide
Anthropic's **Model Context Protocol (MCP)** is an open standard that allows developers to expose data sources and local tools to Large Language Models. By setting up MCP servers inside **claude cowork**, you can connect your desktop assistant directly to databases, code repositories, APIs, and custom local tools.
To set up an MCP server in claude cowork, navigate to Settings > Developer Tools > MCP, and add your server configuration JSON. You can define SQLite queries, Git status checks, or file scanners that Claude runs directly on your device.
Why Connect Databases and APIs to Claude?
By default, an AI model is limited to its training data and the specific text chunks you paste. Whileclaude cowork features include local directory indexing, they don't cover active databases or third-party platforms out of the box. MCP acts as the bridge. Instead of manually exporting database rows to a CSV, Claude can write direct queries to SQLite, analyze results, and generate summaries on demand.
This is particularly transformative for developers, data analysts, and agencies looking to automate reporting pipelines.
Prerequisites
Before adding an MCP server, ensure you have:
- Node.js (v18 or higher) installed on your system.
- Git configured.
- The latest version of claude cowork. Check the installer on our Download page.
Step-by-Step Tutorial: Setting Up a SQLite MCP Server
Let's walk through configuring a connection to a local SQLite database file.
Step 1: Open the MCP Configuration Panel
In the bottom left corner of your claude cowork desktop client, click the gear icon to open **Settings**. Under **Developer Tools**, select **Model Context Protocol (MCP)**.
Step 2: Edit Your Config JSON
Click **Edit Configuration File**. This opens the local `mcp-config.json` file in your system's default text editor. Insert the following block inside the `"mcpServers"` object:
{
"mcpServers": {
"sqlite": {
"command": "npx",
"args": [
"-y",
"@modelcontextprotocol/server-sqlite",
"--db",
"C:/Work/Database/sales.db"
]
}
}
}Note: Ensure you replace `C:/Work/Database/sales.db` with the absolute path to your local database file.
Step 3: Save and Reconnect
Save the JSON file. In the settings panel of claude cowork, click **Restart MCP Daemon**. The client will launch the sqlite server process in the background. You should see a green **Connected** badge appear.
Step 4: Test the Connection
Open a new prompt and type:"Show me the tables in my SQLite database and list the first 5 records in the sales table."
Claude will call the SQLite server tools, run the query on your device, and display the formatted results instantly.
Common Troubleshooting Steps
If your MCP server fails to connect, review these common issues:
- Command Not Found: If you get a spawn error, ensure `node` and `npm` are configured in your system's environment paths.
- Database Path Errors: Verify the database path is absolute and uses forward slashes (e.g. `C:/Folder/file.db` instead of `C:\\Folder\\file.db` which can cause JSON escaping issues).
- Locked Files: If your database is open in another management tool (like SQLite Studio), it may restrict file locks. Close other apps and try restarting the daemon.
Security Warning: Executable Tools
MCP servers run with the permissions of your desktop user. Never run configuration scripts from untrusted sources, and verify that any third-party MCP servers are open-source. For details on how we safeguard your data, read ourPrivacy Policy.
Next Steps
SQLite is just the beginning. You can configure servers for PostgreSQL, GitHub repositories, and local system terminal environments. If you need support setting up custom connectors, check our tutorials in ourGetting Started Guide.
Unlock Desktop Power
Download claude cowork to connect databases, terminal scripts, and API utilities directly to Claude.