LogoSTMCP
Download
Neon MCP Server

Neon MCP Server

Neon MCP Server is an open-source tool that lets you interact with your Neon Postgres databases in natural language.

Tools

1. list_projects

Lists the first 10 Neon projects in your account, providing a summary of each project. If you can't find a specific project, increase the limit by passing a higher value to the limit parameter.

2. describe_project

Fetches detailed information about a specific Neon project, including its ID, name, and associated branches and databases.

3. create_project

Creates a new Neon project in your Neon account. A project acts as a container for branches, databases, roles, and computes.

4. delete_project

Deletes an existing Neon project and all its associated resources.

5. create_branch

Creates a new branch within a specified Neon project. Leverages Neon's branching feature for development, testing, or migrations.

6. delete_branch

Deletes an existing branch from a Neon project.

7. describe_branch

Retrieves details about a specific branch, such as its name, ID, and parent branch.

8. list_branch_computes

Lists compute endpoints for a project or specific branch, including compute ID, type, size, and autoscaling information.

9. list_organizations

Lists all organizations that the current user has access to. Optionally filter by organization name or ID using the search parameter.

10. get_connection_string

Returns your database connection string.

11. run_sql

Executes a single SQL query against a specified Neon database. Supports both read and write operations.

12. run_sql_transaction

Executes a series of SQL queries within a single transaction against a Neon database.

13. get_database_tables

Lists all tables within a specified Neon database.

14. describe_table_schema

Retrieves the schema definition of a specific table, detailing columns, data types, and constraints.

15. list_slow_queries

Identifies performance bottlenecks by finding the slowest queries in a database. Requires the pg_stat_statements extension.

16. prepare_database_migration

Initiates a database migration process. Critically, it creates a temporary branch to apply and test the migration safely before affecting the main branch.

17. complete_database_migration

Finalizes and applies a prepared database migration to the main branch. This action merges changes from the temporary migration branch and cleans up temporary resources.

18. explain_sql_statement

Provides detailed execution plans for SQL queries to help identify performance bottlenecks.

19. prepare_query_tuning

Analyzes query performance and suggests optimizations like index creation. Creates a temporary branch for safely testing these optimizations.

20. complete_query_tuning

Applies or discards query optimizations after testing. Can merge changes from the temporary branch to the main branch.

21. provision_neon_auth

Provisions Neon Auth for a Neon project. It allows developers to easily set up authentication infrastructure by creating an integration with Stack Auth (@stackframe/stack)

JSON Config

{
  "mcpServers": {
    "neon": {
      "command": "npx",
      "args": [
        "-y",
        "@neondatabase/mcp-server-neon",
        "start",
        "<YOUR_NEON_API_KEY>"
      ]
    }
  }
}

Information

Categories