MCP server · Data and analytics
dbt MCP server
The dbt MCP server is dbt Labs’ official MCP server. It lets an assistant run dbt commands on your project and, with a dbt platform account, explore lineage, metrics and job runs. It runs locally with uvx dbt-mcp next to a local dbt project, and its run and build tools change warehouse objects.
- Maintainer
- dbt Labs (official)
- Licence
- Apache-2.0
- Runs
- Locally (uvx)
- Sign-in
- None
- Last activity
- 2026-10-13
Overview
What can the dbt MCP server do?
The dbt MCP server from dbt Labs runs locally with uvx dbt-mcp. Point DBT_PROJECT_DIR at the folder that holds dbt_project.yml and DBT_PATH at your dbt executable, and the assistant can run, build, test, compile and list models in that project. It works with dbt Core and dbt Fusion, with or without a dbt platform account.
Connecting a dbt platform account adds tools for the Semantic Layer, the Discovery API and the Admin API. The assistant can then query metrics, trace model lineage, check model health and source freshness, and list, trigger or retry jobs. SQL execution and code generation tools exist but are off by default. Environment variables such as DISABLE_DBT_CLI turn whole toolsets on or off. dbt Labs also runs a remote server for data consumption only, without CLI commands.
Tools
Tools it gives the assistant
- dbt CLI: run, build, test, compile, parse, list, show
- Local lineage and node details from manifest.json
- Semantic Layer metrics, dimensions and metric queries
- Discovery API: models, sources, lineage and model health
- Admin API: jobs and job runs, including trigger and retry
- Codegen and SQL tools (off by default)
- dbt documentation search
Install
How do I install dbt MCP in Claude Code, Cursor or VS Code?
You need:
- uv (provides uvx)
- A local dbt project and dbt installed
- A dbt platform account only for Semantic Layer, Discovery and Admin API tools
Run in your project. --scope local keeps the servers private to you in this project; use user for every project.
claude mcp add --env DBT_PROJECT_DIR="${DBT_PROJECT_DIR}" --env DBT_PATH="${DBT_PATH}" --scope local dbt -- uvx dbt-mcp
claude mcp add --env DBT_PROJECT_DIR="$env:DBT_PROJECT_DIR" --env DBT_PATH="$env:DBT_PATH" --scope local dbt -- uvx dbt-mcp
- Set DBT_PROJECT_DIR, DBT_PATH first, e.g. export DBT_PROJECT_DIR=… in your shell. The command saves the value, not the variable.
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json · Windows: %APPDATA%\Claude\claude_desktop_config.json (Settings → Developer → Edit Config). Restart Claude after saving.
{
"mcpServers": {
"dbt": {
"command": "uvx",
"args": [
"dbt-mcp"
],
"env": {
"DBT_PROJECT_DIR": "<DBT_PROJECT_DIR>",
"DBT_PATH": "<DBT_PATH>"
}
}
}
}
- Claude Desktop doesn’t read variables in this file: replace <DBT_PROJECT_DIR>, <DBT_PATH> with the real values.
- This file contains your keys once filled in. It lives in your user folder; never commit or share it.
In your project, or ~/.cursor/mcp.json for every project.
{
"mcpServers": {
"dbt": {
"type": "stdio",
"command": "uvx",
"args": [
"dbt-mcp"
],
"env": {
"DBT_PROJECT_DIR": "${env:DBT_PROJECT_DIR}",
"DBT_PATH": "${env:DBT_PATH}"
}
}
}
}
In your workspace. VS Code asks for each secret the first time a server starts and stores it securely.
{
"inputs": [
{
"type": "promptString",
"id": "dbt-project-dir",
"description": "DBT_PROJECT_DIR",
"password": true
},
{
"type": "promptString",
"id": "dbt-path",
"description": "DBT_PATH",
"password": true
}
],
"servers": {
"dbt": {
"type": "stdio",
"command": "uvx",
"args": [
"dbt-mcp"
],
"env": {
"DBT_PROJECT_DIR": "${input:dbt-project-dir}",
"DBT_PATH": "${input:dbt-path}"
}
}
}
}
Need another app? Open dbt MCP Server in the MCP config generator for a shared project .mcp.json, Devin, or several servers at once; it writes one file per app. The snippets follow the setup in the server’s README, checked on 2026-10-14.
Is the dbt MCP server safe? Check before you install
- dbt CLI tools such as run and build change models and warehouse objects; dbt Labs says to enable them only for a client you trust.
- Set DISABLE_DBT_CLI=true, or use DBT_MCP_ENABLE_* allowlists, to limit the toolsets.
- Admin API tools can trigger and cancel jobs in your dbt platform account.
- A local MCP server runs with your user account’s permissions. Install it only from the source linked above. See how to choose a safe server.
FAQ
dbt MCP questions
Is the dbt MCP server official?
Yes. dbt Labs publishes and maintains it, under the Apache-2.0 licence. Install it only from the source linked on this page, not from a copy in another directory.
Is dbt MCP server remote or local?
Local. Your MCP app starts it on your machine with uvx, and it runs with your user account’s permissions.
Does dbt MCP server need an API key or account?
No. It needs no account, API key or sign-in to run. You also need: uv (provides uvx); A local dbt project and dbt installed; A dbt platform account only for Semantic Layer, Discovery and Admin API tools.
Why it’s listed
Why we list it
Official, frequently released and the standard way to give an assistant real dbt project context.
Related
Alternatives and related servers: data and analytics
All MCP serversMCP config generatorGuide: MCP servers in Claude CodeGuide: what is MCP?
Keep exploring