Skip to content
Docs / Cursor

Cursor

Cursor reads MCP servers from a JSON file, per project or globally, and reloads it when you save.

Per project

Create .cursor/mcp.json in the repository root. Everyone who opens the project gets Astron.

.cursor/mcp.jsonjson
{
  "mcpServers": {
    "astron": {
      "url": "https://mcp.astron.design",
      "headers": { "Authorization": "Bearer ${env:ASTRON_KEY}" }
    }
  }
}

${env:ASTRON_KEY} is resolved from each person’s environment, so the file is safe to commit.

For every project

Put the same block in ~/.cursor/mcp.json. A project file with a server of the same name takes precedence.

Verify

Open Settings, then MCP. Astron should show a green dot and six tools. If it shows red, open the output panel and choose MCP Logs; the most common cause is an unset ASTRON_KEY, which Cursor reports as a 401.

Cursor only calls tools in Agent mode. In Ask mode the agent can see Astron but will not call it.