Skip to content
SupportDashboard

Development Setup

Connect an AI assistant to your local Nhost project with the CLI MCP server so it can read your schema, run queries, and manage metadata and migrations.

MCP setup local development AI assistant Cursor Claude Code nhost mcp start install-mcp.md

This guide sets up the Nhost CLI’s MCP server against your local project so an AI assistant can read your GraphQL schema, run queries and mutations, and manage Hasura metadata and migrations while you develop.

If you already have an AI assistant connected to your editor, it can perform the whole setup for you. Give it the onboarding file and let it run:

curl -fsSL https://docs.nhost.io/install-mcp | claude

You can also hand any coding assistant the link https://docs.nhost.io/install-mcp to run the setup autonomously. Prefer the manual steps below? Continue reading.

The MCP server reads .nhost/mcp-nhost.toml from your project directory. Generate it with the interactive wizard:

nhost mcp config

Or create .nhost/mcp-nhost.toml yourself with a single local project. This grants the assistant full read/write access to your local project and enables metadata management:

[[projects]]
subdomain = "local"
region = "local"
description = "Local development project running via the Nhost CLI"
admin_secret = "nhost-admin-secret"
manage_metadata = true
allow_queries = ["*"]
allow_mutations = ["*"]

Point your client at nhost mcp start. The server picks up .nhost/mcp-nhost.toml automatically.

claude mcp add nhost nhost mcp start

For per-client configuration details, see MCP Clients.

Your client should now list the nhost server and its tools: graphql-query, get-schema, manage-graphql, and search. Ask the assistant to fetch your schema, or confirm the server responds directly:

echo '{"jsonrpc":"2.0","method":"tools/call","params":{"name":"get-schema","arguments":{"subdomain":"local","role":"admin","summary":true}},"id":1}' | nhost mcp start

If something is not working, see Troubleshooting.

  • Configuration — scope which queries and mutations the assistant can run.
  • MCP Clients — per-client configuration details.
  • Overview — the full list of tools and resources the server exposes.