Skip to main content

Overview

Datafold provides a public HTTP MCP (Model Context Protocol) server that enables AI assistants to interact with your Datafold data sources, run queries, and manage data diffs. Endpoint: https://app.datafold.com/mcp/v1

Prerequisites

Before setting up the MCP server, you need a Datafold API key.
1

Navigate to Settings

Open the Datafold app and go to Settings > Account
2

Create API Key

Click Create API Key and store it securely
If you lose your API key, you’ll need to generate a new one. See the Introduction guide for more details.

Authentication

The MCP server uses Bearer token authentication with your Datafold API key:
Authorization: Key YOUR_API_KEY
Include this header in your MCP client configuration.

Setup by Client

Claude Desktop supports remote MCP servers through its Connectors feature.Steps:
  1. Open Claude Desktop
  2. Go to Settings > Connectors
  3. Click Add Connector or New Remote Server
  4. Configure the connector:
    • Name: Datafold
    • URL: https://app.datafold.com/mcp/v1
    • Headers:
      {
        "Authorization": "Key YOUR_API_KEY"
      }
      
  5. Save and restart Claude Desktop
Claude Desktop will not connect to remote servers configured via claude_desktop_config.json. Use the Connectors interface.
Claude Code supports MCP through a simple CLI command.Quick Setup:Run the following command in your terminal:
claude mcp add --transport http --scope user \
  datafold https://app.datafold.com/mcp/v1 \
  --header "Authorization: Key YOUR_API_KEY"
Options:
  • --scope user - Makes the server available across all projects
  • --header - Adds authentication header
Verify Installation:
claude mcp list
The Datafold MCP server will now be available in all your Claude Code sessions.
See the Claude Code MCP documentation for more configuration options.
Cursor supports MCP servers through project-specific or global configuration.Project-Specific Setup:Create .cursor/mcp.json in your project directory:
{
  "mcpServers": {
    "datafold": {
      "type": "http",
      "url": "https://app.datafold.com/mcp/v1",
      "headers": {
        "Authorization": "Key YOUR_API_KEY"
      }
    }
  }
}
Restart Cursor to load the configuration.
Cline is a VS Code extension that supports MCP servers.Steps:
  1. Install the Cline extension
  2. Click the MCP Servers icon in Cline’s navigation
  3. Select Configure tab → Advanced MCP Settings
  4. Add to cline_mcp_settings.json:
{
  "mcpServers": {
    "datafold": {
      "type": "http",
      "url": "https://app.datafold.com/mcp/v1",
      "headers": {
        "Authorization": "Key YOUR_API_KEY"
      },
      "timeout": 60000
    }
  }
}
  1. Toggle the switch to enable the server
  2. Close and reopen VS Code
Windsurf supports environment variable interpolation for secure credential storage.Configuration File: ~/.codeium/windsurf/mcp_config.jsonBasic Configuration:
{
  "mcpServers": {
    "datafold": {
      "type": "http",
      "serverUrl": "https://app.datafold.com/mcp/v1",
      "headers": {
        "Authorization": "Key YOUR_API_KEY"
      }
    }
  }
}
Using Environment Variables (Recommended):
{
  "mcpServers": {
    "datafold": {
      "type": "http",
      "serverUrl": "https://app.datafold.com/mcp/v1",
      "headers": {
        "Authorization": "Key ${env:DATAFOLD_API_KEY}"
      }
    }
  }
}
Set DATAFOLD_API_KEY as an environment variable, then restart Windsurf.
Continue.dev supports MCP in agent mode through YAML configuration.Configuration Directory: .continue/mcpServers/Create datafold.yaml:
type: streamable-http
url: https://app.datafold.com/mcp/v1
headers:
  Authorization: "Key YOUR_API_KEY"
MCP can only be used in agent mode within Continue.dev.
Zed supports MCP through custom configuration in settings.Steps:
  1. Open Zed
  2. Go to Preferences > Settings (⌘, on macOS)
  3. Add a context_servers section:
{
  "context_servers": {
    "datafold": {
      "settings": {
        "url": "https://app.datafold.com/mcp/v1",
        "headers": {
          "Authorization": "Key YOUR_API_KEY"
        }
      }
    }
  }
}
  1. Check the Agent Panel - the indicator should be green when active
OpenCode supports both local and remote MCP servers with automatic OAuth handling.Configuration Files:
  • Global: ~/.config/opencode/opencode.json
  • Project: opencode.json in project root (overrides global)
Remote MCP Configuration:
{
  "mcp": {
    "datafold": {
      "type": "remote",
      "url": "https://app.datafold.com/mcp/v1",
      "headers": [
        {
          "name": "Authorization",
          "value": "Key YOUR_API_KEY"
        }
      ],
      "enabled": true
    }
  }
}
CLI Setup: You can also use the interactive CLI to add the server:
opencode mcp add
Then follow the prompts to configure the Datafold remote MCP server.
See the OpenCode MCP documentation for advanced configuration.
Gemini CLI supports MCP servers with built-in OAuth 2.0 authentication.Configuration Files:
  • Global: ~/.gemini/settings.json
  • Project: .gemini/settings.json in project directory
Add via CLI (Recommended):
gemini mcp add datafold --scope user \
  --transport http \
  --url https://app.datafold.com/mcp/v1 \
  --header "Authorization: Key YOUR_API_KEY"
Manual Configuration:Edit your settings file:
{
  "mcpServers": {
    "datafold": {
      "transport": "http",
      "url": "https://app.datafold.com/mcp/v1",
      "headers": {
        "Authorization": "Key YOUR_API_KEY"
      }
    }
  }
}
See the Gemini CLI MCP documentation for OAuth and advanced features.
Kiro supports both global and project-specific MCP configuration.Global Configuration:Edit ~/.kiro/settings/mcp.json:
{
  "mcpServers": {
    "datafold": {
      "url": "https://app.datafold.com/mcp/v1",
      "headers": {
        "Authorization": "Key YOUR_API_KEY"
      }
    }
  }
}
Project-Specific Configuration:Edit .kiro/settings/mcp.json in your project directory with the same format.Using Environment Variables (Recommended):
{
  "mcpServers": {
    "datafold": {
      "url": "https://app.datafold.com/mcp/v1",
      "headers": {
        "Authorization": "Key ${API_TOKEN}"
      }
    }
  }
}
Changes apply automatically when you save the file.
See the Kiro MCP documentation for advanced options.

Verification

After configuring your MCP client, verify the connection:
  1. Check that the server status shows as “active” or “connected”
  2. Test with a simple query:
    • “List my Datafold data sources”
    • “Run a query against [data source name]”
If successful, your AI assistant can now interact with Datafold through MCP.

Troubleshooting

Symptoms: “Unable to connect to MCP server” or “No valid session ID”Solutions:
  • Verify your API key is valid
  • Confirm the URL is exactly https://app.datafold.com/mcp/v1
  • Check header format: Authorization: Key YOUR_API_KEY
  • Regenerate your API key if issues persist
Symptoms: “401 Unauthorized” or “403 Forbidden”Solutions:
  • Generate a new API key if needed
  • Verify the header uses Key prefix (not Bearer)
  • Check your API key hasn’t been revoked
Symptoms: MCP server doesn’t appear or shows as inactiveSolutions:
  • Restart your MCP client completely
  • Validate JSON/YAML syntax
  • Check client logs for specific errors
  • Ensure configuration file is in the correct location

Best Practices

Secure Your Keys

Never commit API keys to version control. Use environment variables or secure secret management.

Use Environment Variables

Reference API keys through environment variables rather than hardcoding them in configuration files.

Monitor Usage

Regularly check Datafold audit logs to monitor API usage and detect anomalies.

Rotate Keys

Periodically rotate your API keys as part of security best practices.

Additional Resources


Support

If you need assistance: