The free build of Claude Code. All telemetry removed, security-prompt guardrails stripped, all experimental features enabled.
The free build of Claude Code. All telemetry removed, security-prompt guardrails stripped, all experimental features enabled.
The free build of Claude Code.
All telemetry stripped. All guardrails removed. All experimental features unlocked.
One binary, zero callbacks home.
curl -fsSL https://raw.githubusercontent.com/paoloanzn/free-code/main/install.sh | bashChecks your system, installs Bun if needed, clones the repo, builds with all experimental features enabled, and symlinks free-code on your PATH.
Then run free-code and use the /login command to authenticate with your preferred model provider.
A clean, buildable fork of Anthropic's Claude Code CLI -- the terminal-native AI coding agent. The upstream source became publicly available on March 31, 2026 through a source map exposure in the npm distribution.
This fork applies three categories of changes on top of that snapshot:
The upstream binary phones home through OpenTelemetry/gRPC, GrowthBook analytics, Sentry error reporting, and custom event logging. In this build:
Anthropic injects system-level instructions into every conversation that constrain Claude's behavior beyond what the model itself enforces. These include hardcoded refusal patterns, injected "cyber risk" instruction blocks, and managed-settings security overlays pushed from Anthropic's servers.
This build strips those injections. The model's own safety training still applies -- this just removes the extra layer of prompt-level restrictions that the CLI wraps around it.
Claude Code ships with 88 feature flags gated behind bun:bundle compile-time switches. Most are disabled in the public npm release. This build unlocks all 54 flags that compile cleanly. See Experimental Features below, or refer to FEATURES.md for the full audit.
free-code supports five API providers out of the box. Set the corresponding environment variable to switch providers -- no code changes needed.
Use Anthropic's first-party API directly.
| Model | ID |
|---|---|
| Claude Opus 4.6 | claude-opus-4-6 |
| Claude Sonnet 4.6 | claude-sonnet-4-6 |
| Claude Haiku 4.5 | claude-haiku-4-5 |
Use OpenAI's Codex models for code generation. Requires a Codex subscription.
| Model | ID |
|---|---|
| GPT-5.3 Codex (recommended) | gpt-5.3-codex |
| GPT-5.4 | gpt-5.4 |
| GPT-5.4 Mini | gpt-5.4-mini |
export CLAUDE_CODE_USE_OPENAI=1
free-codeRoute requests through your AWS account via Amazon Bedrock.
export CLAUDE_CODE_USE_BEDROCK=1
export AWS_REGION="us-east-1" # or AWS_DEFAULT_REGION
free-codeUses your standard AWS credentials (environment variables, ~/.aws/config, or IAM role). Models are mapped to Bedrock ARN format automatically (e.g., us.anthropic.claude-opus-4-6-v1).
| Variable | Purpose |
|---|---|
CLAUDE_CODE_USE_BEDROCK |
Enable Bedrock provider |
AWS_REGION / AWS_DEFAULT_REGION |
AWS region (default: us-east-1) |
ANTHROPIC_BEDROCK_BASE_URL |
Custom Bedrock endpoint |
AWS_BEARER_TOKEN_BEDROCK |
Bearer token auth |
CLAUDE_CODE_SKIP_BEDROCK_AUTH |
Skip auth (testing) |
Route requests through your GCP project via Vertex AI.
export CLAUDE_CODE_USE_VERTEX=1
free-codeUses Google Cloud Application Default Credentials (gcloud auth application-default login). Models are mapped to Vertex format automatically (e.g., claude-opus-4-6@latest).
Use Anthropic Foundry for dedicated deployments.
export CLAUDE_CODE_USE_FOUNDRY=1
export ANTHROPIC_FOUNDRY_API_KEY="..."
free-codeSupports custom deployment IDs as model names.
| Provider | Env Variable | Auth Method |
|---|---|---|
| Anthropic (default) | -- | ANTHROPIC_API_KEY or OAuth |
| OpenAI Codex | CLAUDE_CODE_USE_OPENAI=1 |
OAuth via OpenAI |
| AWS Bedrock | CLAUDE_CODE_USE_BEDROCK=1 |
AWS credentials |
| Google Vertex AI | CLAUDE_CODE_USE_VERTEX=1 |
gcloud ADC |
| Anthropic Foundry | CLAUDE_CODE_USE_FOUNDRY=1 |
ANTHROPIC_FOUNDRY_API_KEY |
# Install Bun if you don't have it
curl -fsSL https://bun.sh/install | bashgit clone https://github.com/paoloanzn/free-code.git
cd free-code
bun build
./cli| Command | Output | Features | Description |
|---|---|---|---|
bun run build |
./cli |
VOICE_MODE only |
Production-like binary |
bun run build:dev |
./cli-dev |
VOICE_MODE only |
Dev version stamp |
bun run build:dev:full |
./cli-dev |
All 54 experimental flags | Full unlock build |
bun run compile |
./dist/cli |
VOICE_MODE only |
Alternative output path |
Enable specific flags without the full bundle:
# Enable just ultraplan and ultrathink
bun run ./scripts/build.ts --feature=ULTRAPLAN --feature=ULTRATHINK
# Add a flag on top of the dev build
bun run ./scripts/build.ts --dev --feature=BRIDGE_MODE# Interactive REPL (default)
./cli
# One-shot mode
./cli -p "what files are in this directory?"
# Specify a model
./cli --model claude-opus-4-6
# Run from source (slower startup)
bun run dev
# OAuth login
./cli /login| Variable | Purpose |
|---|---|
ANTHROPIC_API_KEY |
Anthropic API key |
ANTHROPIC_AUTH_TOKEN |
Auth token (alternative) |
ANTHROPIC_MODEL |
Override default model |
ANTHROPIC_BASE_URL |
Custom API endpoint |
ANTHROPIC_DEFAULT_OPUS_MODEL |
Custom Opus model ID |
ANTHROPIC_DEFAULT_SONNET_MODEL |
Custom Sonnet model ID |
ANTHROPIC_DEFAULT_HAIKU_MODEL |
Custom Haiku model ID |
CLAUDE_CODE_OAUTH_TOKEN |
OAuth token via env |
CLAUDE_CODE_API_KEY_HELPER_TTL_MS |
API key helper cache TTL |
The bun run build:dev:full build enables all 54 working feature flags. Highlights:
| Flag | Description |
|---|---|
ULTRAPLAN |
Remote multi-agent planning on Claude Code web (Opus-class) |
ULTRATHINK |
Deep thinking mode -- type "ultrathink" to boost reasoning effort |
VOICE_MODE |
Push-to-talk voice input and dictation |
TOKEN_BUDGET |
Token budget tracking and usage warnings |
HISTORY_PICKER |
Interactive prompt history picker |
MESSAGE_ACTIONS |
Message action entrypoints in the UI |
QUICK_SEARCH |
Prompt quick-search |
SHOT_STATS |
Shot-distribution stats |
| Flag | Description |
|---|---|
BUILTIN_EXPLORE_PLAN_AGENTS |
Built-in explore/plan agent presets |
VERIFICATION_AGENT |
Verification agent for task validation |
AGENT_TRIGGERS |
Local cron/trigger tools for background automation |
AGENT_TRIGGERS_REMOTE |
Remote trigger tool path |
EXTRACT_MEMORIES |
Post-query automatic memory extraction |
COMPACTION_REMINDERS |
Smart reminders around context compaction |
CACHED_MICROCOMPACT |
Cached microcompact state through query flows |
TEAMMEM |
Team-memory files and watcher hooks |
| Flag | Description |
|---|---|
BRIDGE_MODE |
IDE remote-control bridge (VS Code, JetBrains) |
BASH_CLASSIFIER |
Classifier-assisted bash permission decisions |
PROMPT_CACHE_BREAK_DETECTION |
Cache-break detection in compaction/query flow |
See FEATURES.md for the complete audit of all 88 flags, including 34 broken flags with reconstruction notes.
…| Runtime | Bun |
| Language | TypeScript |
| Terminal UI | React + Ink |
| CLI Parsing | Commander.js |
| Schema Validation | Zod v4 |
| Code Search | ripgrep (bundled) |
| Protocols | MCP, LSP |
| APIs | Anthropic Messages, OpenAI Codex, AWS Bedrock, Google Vertex AI |
A full copy of this repository is permanently pinned on IPFS via Filecoin:
| CID | bafybeiegvef3dt24n2znnnmzcud2vxat7y7rl5ikz7y7yoglxappim54bm |
| Gateway | https://w3s.link/ipfs/bafybeiegvef3dt24n2znnnmzcud2vxat7y7rl5ikz7y7yoglxappim54bm |
If this repo gets taken down, the code lives on.
Contributions are welcome. If you're working on restoring one of the 34 broken feature flags, check the reconstruction notes in FEATURES.md first -- many are close to compiling and just need a small wrapper or missing asset.
git checkout -b feat/my-feature)git commit -m 'feat: add something')git push origin feat/my-feature)The original Claude Code source is the property of Anthropic. This fork exists because the source was publicly exposed through their npm distribution. Use at your own discretion.
How to run Claude Code free with AgentRouter
--dangerously-skip-permissions ?
支持deepseek4
Nvidia NIM OpenAI-kompatible API + Kimi K2 Integration (ANTHROPIC_BASE_URL Hack)
Windows support without WSL2
Ban from anthropic ?
[BUG] Free Code resubmits a tool result after a post-tool provider disconnect
[BUG] free-code repeats completed shell tool results
The V112 cch signing bytes changed
Opus 4.7 Thinking API