Guides
VS Code Setup
Configure VS Code MCP extension for n8n workflows
VS Code Setup
Connect Visual Studio Code to n8n MCP Bridge using the MCP extension.
Prerequisites
- VS Code installed
- n8n MCP Bridge running
- MCP API key created
Installation
Step 1: Install MCP Extension
- Open VS Code
- Go to Extensions (Cmd/Ctrl+Shift+X)
- Search for "Model Context Protocol" or "MCP"
- Click Install
Step 2: Configure Extension
- Open VS Code Settings (Cmd/Ctrl+,)
- Search for "MCP"
- Find "MCP: Servers" setting
- Click "Edit in settings.json"
Add this configuration:
{
"mcp.servers": {
"n8n": {
"url": "http://localhost:3001/mcp?apiKey=mcp_your_key_here"
}
}
}
Step 3: Reload VS Code
- Press Cmd/Ctrl+Shift+P
- Type "Reload Window"
- Press Enter
Verification
Test the connection:
- Open Command Palette (Cmd/Ctrl+Shift+P)
- Type "MCP: Test Connection"
- Select "n8n"
- Should show "Connected ✓"
Using MCP in VS Code
In Chat
Use VS Code's AI chat:
@mcp Can you ping my n8n instance?
In Terminal
Some extensions allow terminal integration:
mcp n8n ping_n8n
Configuration Options
Multiple Servers
{
"mcp.servers": {
"n8n-prod": {
"url": "https://mcp.example.com/mcp?apiKey=mcp_prod"
},
"n8n-dev": {
"url": "http://localhost:3001/mcp?apiKey=mcp_dev"
}
}
}
Workspace-Specific
Create .vscode/settings.json in your project:
{
"mcp.servers": {
"n8n": {
"url": "http://localhost:3001/mcp?apiKey=mcp_project_key"
}
}
}
Troubleshooting
Extension Not Found
If MCP extension isn't available:
- Check VS Code version (may require recent version)
- Look for alternative extensions
- Use Claude Desktop instead
Connection Failed
- Verify MCP server is running:
curl http://localhost:3001/health - Check API key in settings.json
- Reload VS Code window
- Check extension logs