Neon — Claude Code MCP server: Postgres in plain language
Runs Neon projects and Lakebase Postgres databases from chat: branches, queries, migrations. Useful when you would rather not open the console or hand-write SQL.
claude mcp add --transport http mcp https://mcp.neon.tech/mcpWhat Neon does
The server sits between your plain-language request and the Neon API. You describe what should happen to the database, and it turns that into API calls. Creating a project, branching, running a query, changing a schema — all of it goes through the agent conversation.
Setup comes in three flavours. The quick one is npx neon@latest init: it handles OAuth, generates an API key and wires up your editor. The hosted server with OAuth needs no key in the client config. The third option is the same hosted endpoint with an API key, for cases where OAuth is not available. Local development wants Node.js 22 or newer, and pnpm arrives through Corepack — activate it with corepack enable.
The tool is meant for local development and IDE integrations. The author warns against running it in production, since the operations it can perform may change or drop data. With IP Allow turned on, add 34.192.103.46 and 23.22.233.166 to the allowlist, or mcp.neon.tech will not get through.
What it helps with
- spin up a Neon project and a table without writing SQL
- apply a schema migration through a branch
- see what data sits in each project
- add a column to an existing table
- hook a database up to an agent in the IDE
Example prompts for the agent
- Create a new Postgres database called
my-database, then add auserstable with id, name, email and password columns. - Run a migration on
my-projectthat adds acreated_atcolumn to theuserstable. - Give me a summary of all my Neon projects and what data each one holds.
How to install Neon
Platform CLI: remote server
claude mcp add --transport http mcp https://mcp.neon.tech/mcpPlatform CLI: remote server
codex mcp add neon --url https://mcp.neon.tech/mcpConfig file
{
"mcpServers": {
"neon": {
"url": "https://mcp.neon.tech/mcp"
}
}
}Config file
{
"servers": {
"neon": {
"type": "http",
"url": "https://mcp.neon.tech/mcp"
}
}
}Platform CLI: remote server
gemini mcp add -t http neon https://mcp.neon.tech/mcpStep by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more
Questions about Neon
How do I install the Neon MCP server in Claude Code?
Add the hosted server with claude mcp add --transport http neon https://mcp.neon.tech/mcp. You will authenticate through OAuth the first time it is used.
What does the Neon MCP server do?
It converts natural-language requests into Neon API calls: creating projects and branches, running queries, applying schema migrations. It works with Lakebase Postgres databases.
Can I use it in production?
The author advises against it, because the server can execute operations that alter or remove data. Keep it for local development and IDE integrations.