Neon MCP server

OfficialNeon606Config last verified Jun 1, 2026

Neon's official MCP server lets agents create projects and branches, run SQL, and drive safe schema migrations on serverless Postgres.

The Neon MCP Server is the official server from Neon, the serverless Postgres platform, that lets an AI agent manage your databases through natural language. It exposes the full Neon control plane: list, create, describe, and delete projects; spin up and tear down database branches (Neon's instant copy-on-write clones); fetch connection strings; and run SQL queries and transactions directly. Where it really shines is safe schema change: the prepare_database_migration / complete_database_migration pair applies a migration to a temporary branch first so the agent can verify it before touching production, and the query-tuning tools do the same for performance work, testing an optimization on a branch before committing. It also surfaces slow queries, EXPLAIN plans, and can provision Neon Auth and the Data API.

The canonical deployment is the hosted remote endpoint at https://mcp.neon.tech/mcp, which uses OAuth so an interactive client opens a browser window to authorize access to your Neon account with no key handling. For remote agents or headless setups you can instead run the local @neondatabase/mcp-server-neon package, or point a client at the remote URL with a NEON_API_KEY passed as a bearer token. Branch-first migrations make it one of the safer ways to let an agent change a live database.

Quick install

Copy-paste configs are provided for all 8 supported clients. Pick your client below.

Add to ~/.claude.json

~/.claude.json
json
{
  "mcpServers": {
    "neon": {
      "type": "http",
      "url": "https://mcp.neon.tech/mcp"
    }
  }
}
Or via CLI
bash
claude mcp add --transport http neon https://mcp.neon.tech/mcp

Heads up

  • First tool call opens a browser to authorize.

Available tools

ToolDescription
list_projectsLists the first 10 Neon projects for the authenticated account with summaries.
list_shared_projectsLists projects that have been shared with the current user.
describe_projectGets detailed information about a specific Neon project.
create_projectCreates a new Neon project.
delete_projectDeletes a Neon project and its resources.
list_organizationsLists organizations the user has access to.
create_branchCreates a new database branch in a project.
delete_branchDeletes a branch from a project.
describe_branchFetches details about a branch, including its objects.
list_branch_computesLists the compute endpoints attached to branches.
compare_database_schemaShows the schema differences between two branches.
reset_from_parentResets a branch to the current state of its parent branch.
get_connection_stringRetrieves a Postgres connection string for a project or branch.
run_sqlExecutes a single SQL statement (read or write) against a database.
run_sql_transactionRuns multiple SQL statements as a single transaction.
get_database_tablesLists all tables in a database.
describe_table_schemaDescribes the column structure of a table.
prepare_database_migrationBegins a safe schema migration by applying it to a temporary branch for verification.
complete_database_migrationApplies a verified migration to the main branch.
list_slow_queriesIdentifies slow queries to surface performance problems.
explain_sql_statementReturns the execution plan for a SQL statement.
prepare_query_tuningTests query optimizations safely on a temporary branch.
complete_query_tuningApplies or discards changes from a query-tuning session.
provision_neon_authProvisions Neon Auth authentication infrastructure for a project.
provision_neon_data_apiSets up the Neon Data API for HTTP-based database access.
searchSearches across organizations, projects, and branches.
fetchFetches detailed information about a specific resource.
list_docs_resourcesIndexes the available Neon documentation resources.
get_doc_resourceRetrieves a specific Neon documentation page.

Required configuration

  • NEON_API_KEYOptional

    Neon API key, used as a bearer token for remote agents or headless setups when OAuth is unavailable. Not required for the standard OAuth flow.

What you can do with it

Migrate a schema safely

The agent applies a schema change to a temporary Neon branch with prepare_database_migration, verifies it, then promotes it to production with complete_database_migration so a bad migration never hits the main branch.

Spin up a throwaway database

Ask the agent to create a project or branch, hand it the connection string, run experiments, then delete the branch when finished, all without leaving the editor.

FAQ

Is it free?
Yes. The MCP server is open source and free to run; it operates within your existing Neon account and plan limits, including the generous free tier.
Does it support remote/OAuth?
Yes. The canonical deployment is the hosted remote endpoint at https://mcp.neon.tech/mcp with OAuth, which opens a browser window to authorize access. For remote agents you can pass a NEON_API_KEY as a bearer token, or run the local @neondatabase/mcp-server-neon package.
Can the agent change production data?
It can run write SQL and migrations, but the migration and query-tuning tools apply changes to a temporary branch first so they can be verified before being promoted to the main branch.
← Browse all databases servers