Home / Learn / Unlimited Claude Code Usage — No Token Limits
Unlimited Claude Code Usage — No Token Limits — No Token Limits

Unlimited Claude Code Usage — No Token Limits

Claude Code is the number one token consumer among AI developer tools. Its stateless architecture resends the full conversation with every turn, subagents multiply context windows, and heavy sessions easily burn through millions of tokens per day. Official plans — even Claude Max at $200/month — have fair-use caps that active developers hit within days. Unlimited flat-rate access removes these caps entirely, turning Claude Code from a rationed resource into a true always-on development partner.

Why Claude Code Hits Limits Faster Than Anything Else

Claude Code's token consumption is fundamentally different from chat-based Claude usage. In chat, you send a message and receive a reply — two modest token events. In Claude Code, every turn resends the entire conversation history (all previous messages, file contents, tool results, assistant responses) plus the new input. By the tenth turn, each request carries tens of thousands of tokens of accumulated context.

This is compounded by how developers actually work. A Claude Code session involves reading files (each read adds thousands of tokens to context), making edits (the before/after content stays in history), running commands (output added to context), and iterating (each iteration carries all previous iterations). A 30-minute focused session on a medium codebase easily consumes 500K-1M total tokens across all requests combined.

Subagents and agent teams multiply this further. Each subagent is a separate conversation with its own growing context. A parent agent dispatching work to three subagents effectively runs four parallel token-consuming sessions. Background agents run continuously, accumulating tokens over hours. The total consumption for a day of active development with agent teams can reach 5-10 million tokens — far beyond what any capped plan comfortably supports. This is not hypothetical; it is the normal operating mode for developers who use Claude Code's full feature set.

How Official Plans Fall Short for Heavy Claude Code

Claude Max at $200/month offers '20x' usage compared to Pro, but in concrete terms this still has fair-use caps. Developers who use Claude Code as their primary tool — 4-6 hours of active coding per day — consistently report hitting these caps within the first 5-7 days of a billing period. The remaining 3 weeks become either throttled or require supplemental pay-as-you-go API access.

Direct Anthropic API billing has no caps but no predictability either. A heavy Claude Code day on Opus can cost $30-50 in raw API fees. Over a month of daily development, that is $600-1000+ for a single developer. The bill varies wildly based on task complexity, codebase size, and how many subagents you use. Budget forecasting becomes guesswork.

Both approaches create the same developer behavior: self-censoring. You hesitate before asking exploratory questions. You compact aggressively and lose useful context. You avoid subagents to save tokens. You choose Sonnet over Opus even when Opus would produce better results. You avoid background agents entirely. The tool is designed for intensive autonomous work, but the billing model punishes you for using it that way.

Setup: Two Environment Variables

Connecting Claude Code to the unlimited gateway requires exactly two environment variables. Set ANTHROPIC_BASE_URL to https://claudeapikey.dev (root host, no /v1 — the SDK adds the path). Set ANTHROPIC_API_KEY to your key from the gateway dashboard. That is it. Claude Code immediately routes all requests through the gateway.

Add these to your shell profile for persistent configuration: ~/.bashrc or ~/.zshrc on Linux/macOS, or $PROFILE in PowerShell on Windows. Alternatively, create a .env file in your project root for per-project configuration. Claude Code loads .env files from the working directory automatically. Restart your terminal or Claude Code session after setting the variables.

Optional but recommended: set ANTHROPIC_DEFAULT_OPUS_MODEL=claude-opus-4-6 and ANTHROPIC_DEFAULT_SONNET_MODEL=claude-sonnet-4-5 to ensure Claude Code uses the correct model identifiers. Also set CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC=1 to reduce noise. With these four variables set, your Claude Code installation is fully configured for unlimited usage with optimal model selection and minimal unnecessary network traffic.

Workflows That Become Possible Without Caps

Long refactoring sessions: instead of compacting every 10 turns to manage cost, let the context grow naturally until quality degrades. Claude Code with a full, rich context produces better results because it remembers every decision, every file it read, every approach that was tried and rejected. Compact only for quality, not for cost.

Subagent-heavy workflows: delegate freely. Use agent teams for parallel implementation across multiple modules. Let the coordinator agent spawn as many workers as the task needs. Run background agents that monitor test results, check build output, or review code changes asynchronously. Each agent is a separate context that would cost money individually — on unlimited, they are all covered.

Overnight and long-running agents: start a background agent on a large refactoring task before leaving for the day. Let it work through the entire codebase, reading hundreds of files, making changes, running tests, iterating. On per-token billing, an overnight agent on Opus could cost $50-100 by morning. On unlimited, it costs exactly $0 extra. This makes batch-scale development automation economically viable for individual developers.

Real Workflow: Full-Codebase Feature Implementation

Consider implementing a new feature that touches 15 files across 4 modules. On capped or pay-as-you-go access, you would manually stage the work: read files yourself, plan in your head, ask Claude Code to edit one file at a time, compact between files to manage context and cost. The process is artificial — you are working around billing constraints, not solving the engineering problem.

On unlimited: tell Claude Code to implement the feature. Let it read all relevant files (adding them all to context), plan the implementation across all modules, implement changes file by file while maintaining full awareness of all other changes, run tests, iterate on failures, and deliver the complete feature. The entire workflow runs in one session with growing context, no artificial compaction, and no cost-driven interruptions. You focus on reviewing the result, not managing the process.

The difference is not just convenience — it is quality. Claude Code with full context of all 15 files makes more coherent cross-file changes. It remembers the interface it defined in file 3 when implementing file 12. It catches consistency issues that would slip through when working file-by-file with compacted context. Unlimited access enables a fundamentally better development workflow, not just a cheaper one.

# Complete Claude Code unlimited setup:

# Add to ~/.bashrc or ~/.zshrc:
export ANTHROPIC_BASE_URL="https://claudeapikey.dev"
export ANTHROPIC_API_KEY="your-key"
export ANTHROPIC_DEFAULT_SONNET_MODEL="claude-sonnet-4-5"
export ANTHROPIC_DEFAULT_OPUS_MODEL="claude-opus-4-6"
export CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC=1

# Reload shell:
source ~/.bashrc

# Start Claude Code — unlimited usage active:
claude

# Use freely:
# /model opus         — switch to Opus for complex tasks
# /effort max         — maximum reasoning depth
# (no need to /compact for cost — only for quality)
# Subagents, agent teams, background agents — all covered

Frequently asked questions

Does unlimited Claude Code mean no rate limits at all?
It means no per-token billing — your usage is not metered by token count. Fair-use rate limits (requests per minute) still apply to keep the service stable. These are generous enough for sustained heavy development including subagents and agent teams.

How do I set up unlimited Claude Code?
Set two environment variables: ANTHROPIC_BASE_URL=https://claudeapikey.dev and ANTHROPIC_API_KEY=your-key. Purchase an unlimited plan ($9/day or $39/week) from the dashboard. Claude Code immediately has unlimited access.

Can I run subagents and agent teams on unlimited?
Yes. All agent conversations — parent, subagents, background agents, agent teams — are covered by the flat rate. There is no per-agent or per-conversation charge. Use agent teams freely for parallel development work.

Is Opus included for Claude Code on unlimited?
Yes. All models are included equally. Set ANTHROPIC_DEFAULT_OPUS_MODEL=claude-opus-4-6 and use /model opus in Claude Code for maximum reasoning quality at no extra per-token cost.

What happens if I still /compact on unlimited?
Compacting still works and is still useful — but for quality reasons, not cost reasons. Compact when the context has become noisy with irrelevant old information. Do not compact just to save tokens — on unlimited there is no cost benefit to shorter context.

Start using Claude in minutes

Get an API key — no Anthropic account or waitlist required.

Get your API key

Claude API Key is an independent API gateway. It is not affiliated with, endorsed by, or a reseller of Anthropic. Claude and related model names are trademarks of their respective owners.