---
title: Install the MCP server
description: Add shebang to Claude Code or any stdio MCP harness with npx -y shebang-mcp.
---

# Install the MCP server

shebang ships one MCP server and CLI, `shebang-mcp`, published on npm —
`npx` runs it with no separate install step.

## Claude Code

```bash
claude mcp add shebang -- npx -y shebang-mcp
npx -y shebang-mcp login
```

The first command registers the server; the second logs it in (see
[device login](/getting-started/device-flow-login) for what that does).

## Any other stdio-based MCP harness

Add this server entry to your harness's config:

```json
{
  "mcpServers": {
    "shebang": {
      "command": "npx",
      "args": ["-y", "shebang-mcp"]
    }
  }
}
```

Then run the same `login` command once, from a terminal on the same
machine.

## Install from source instead

`npx -y github:New-Kringster/shebang-mcp` runs the latest commit on
`main` instead of the published release — useful if you need a fix that
hasn't shipped to npm yet.

## Skip the login flow

If you already have a key (see
[your first key](/getting-started/your-first-key)), set
`SHEBANG_API_KEY` in the environment instead of running `login` — the
server reads it directly, and it takes priority over any saved
credentials file.

## Where the key lives

`login` writes the issued key to `~/.config/shebang/credentials.json`
(mode `0600`). Every harness on that machine that runs this server picks
it up automatically — no per-project setup needed. `shebang-mcp status`
shows the current key's prefix and tier; `shebang-mcp logout` deletes the
local file only — it does not revoke the key on the server.

## Next

[Device login](/getting-started/device-flow-login) — what actually
happens when you run `login`.
