> ## Documentation Index
> Fetch the complete documentation index at: https://inference-docs.cerebras.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Cerebras Code MCP Server

> Learn how to install, configure, and integrate the Cerebras Code MCP server with supported editors.

<Tip>
  [Get a free API key](https://cloud.cerebras.ai/?utm_source=3pi_code-mcp\&utm_campaign=integrations) to get started.
</Tip>

The [**Cerebras Code MCP Server**](https://www.npmjs.com/package/cerebras-code-mcp?utm_source=cerebras\&utm_campaign=code-mcp) accelerates code generation in your existing IDEs and CLI tools (like Cursor and Claude Code) by up to 20x compared to GPUs. It leverages Cerebras fast inference through the **Model Context Protocol** and offers optional graceful fallback via OpenRouter.

MCP provides an open standard that enables AI models to securely interact with tools, data, and editors. Rather than limiting models to plain text chat, MCP grants them structured access to external systems like your IDE, allowing them to read, write, and modify code with consistent rules. This approach ensures safer, more reliable, and more predictable model-driven coding.

<Note>
  The Cerebras Code MCP server is currently in research preview and is [open source here](https://github.com/kevint-cerebras/cerebras-code-mcp?utm_source=cerebras\&utm_campaign=code-mcp). We welcome contributions!
</Note>

<Steps>
  <Step title="Set up your API key">
    You need a valid Cerebras API key. Visit the [Cerebras Cloud console](https://cloud.cerebras.ai/?utm_source=3pi_code-mcp\&utm_campaign=integrations) and sign up, then click on **API Keys** in the left navigation.

    <Note>
      Optionally, [create an OpenRouter key here](https://openrouter.ai/?utm_source=cerebras\&utm_campaign=code-mcp) to use as fallback if you hit Cerebras rate limits.
    </Note>
  </Step>

  <Step title="Install the NPM Package">
    Open your preferred IDE and run the following code in your terminal:

    ```bash theme={null}
    npm install -g cerebras-code-mcp
    ```
  </Step>

  <Step title="Run the Setup Wizard">
    In your terminal, run:

    ```bash theme={null}
    cerebras-mcp --config
    ```

    This will begin the setup process where you can configure different editors (like Claude Code) and set API keys for Cerebras and OpenRouter.

    <Accordion title="Claude Code" description="Enable MCP usage with Claude Code" icon="rectangle-terminal">
      Run the following to verify the setup:

      ```bash theme={null}
      claude mcp list
      ```

      The output should look like this:

      ```bash theme={null}
      Checking MCP server health...

      cerebras-code: cerebras-mcp  - ✓ Connected  
      ```
    </Accordion>
  </Step>
</Steps>

## Available Models

The Cerebras Code MCP Server supports all Cerebras models:

| Model            | Parameters | Best For                                                         |
| ---------------- | ---------- | ---------------------------------------------------------------- |
| **gpt-oss-120b** | 120B       | Largest model for the most demanding tasks                       |
| **zai-glm-4.7**  | 357B       | Advanced 357B parameter model with strong reasoning capabilities |

Configure your preferred model during the setup wizard or in your MCP configuration file.
