> For clean Markdown content of this page, append .md to this URL. For the complete documentation index, see https://buildwithfern.com/learn/llms.txt. # Fern's MCP server > Connect your coding agent to a private MCP server with your organization's Fern data and full context on Fern's documentation and configuration. Fern hosts a private [Model Context Protocol (MCP)](https://modelcontextprotocol.io) server for your organization, with full context on Fern's documentation and configuration alongside your live Fern data. Register it with your coding agent to look up `docs.yml` syntax, components, and CLI commands while you build, and to read your sites, deployments, and reader activity without leaving your terminal. Your own customers connect to the [MCP server Fern generates for your documentation site](/learn/docs/ai-features/mcp-server). ## What it can do Each connection is scoped to a single organization, and the server returns only what your Fern account can already see. The server has access to the same tools as [Fern Agent](/learn/docs/ai-features/fern-agent), including: * **Sites and configuration**: your docs sites, their `docs.yml` configuration and Dashboard settings, and the Markdown source of published pages * **Deployments**: deployment history, and pull request status and preview URLs for connected repositories * **Analytics**: traffic summaries, top pages, 404s, referring domains, and LLM bot traffic * **Reader signals**: search queries, Ask Fern conversations and resolution rates, and page feedback * **Members**: the people in your organization ## Setup Open the [Fern Dashboard](https://dashboard.buildwithfern.com/). From the [Fern Agent chat panel](/learn/docs/ai-features/fern-agent), click **Onboard your agent** to connect your coding agent to the MCP server. ![The Fern Agent chat panel in the Fern Dashboard](/learn/_fern-img/fcc99e1357a9c85d8d600b8f692c2565f2a19ca88cfb8a5c7bdcaa3a04d987b8.webp) ![The Fern Agent chat panel in the Fern Dashboard](/learn/_fern-img/8b59615cd274c6043fcbd008d9b8b3e54611a090ed186258a46b945fdd859ff3.webp) Alternatively, you can set it up directly from your terminal: #### terminal ```bash npm install -g fern-api fern login fern mcp install ``` Agents load MCP servers at startup, so one registered mid-session becomes callable in the next session. ### Multiple organizations If your Fern account belongs to more than one organization, tool calls return the organization-scoped URLs to pick from. Pass `fern mcp install --org ` to pick one, or register again by hand with the URL you want: #### Claude Code ```bash claude mcp add --transport http fern-org https://fai.buildwithfern.com/organizations/{{YOUR_ORGANIZATION}}/mcp ``` #### Codex ```bash codex mcp add fern-org --url https://fai.buildwithfern.com/organizations/{{YOUR_ORGANIZATION}}/mcp ``` #### Cursor (.cursor/mcp.json) ```json { "mcpServers": { "fern-org": { "url": "https://fai.buildwithfern.com/organizations/{{YOUR_ORGANIZATION}}/mcp" } } } ``` #### GitHub Copilot (.vscode/mcp.json) ```json { "servers": { "fern-org": { "url": "https://fai.buildwithfern.com/organizations/{{YOUR_ORGANIZATION}}/mcp" } } } ``` > Connect your coding agent to a private MCP server with your organization's Fern data and full context on Fern's documentation and configuration.