Claude Code Too Expensive? Cut 90%+ Cost with DeepSeek V4 in 10 Minutes
Looking for a cheaper Claude Code stack? Keep the CLI, swap the backend to DeepSeek V4—often 90%+ lower API cost.
Editorial original
Written by WayToClawEarn editorial; cite this page as the primary analysis.
10 Claude Code DeepSeek V4 ——API 90%+
- Claude Code DeepSeek V4 Flash 1 / token
- Claude Code
- API
- Claude Code macOS / Linux
- DeepSeek 10
DeepSeek Claude Code
Claude Code AI Anthropic API ——Claude Sonnet 15 / tokenOpus DeepSeek V4 API Anthropic 5%-10% Claude Sonnet
Claude Code
| Anthropic API | DeepSeek V4 | |
|---|---|---|
| token | 15 Sonnet | 1 Flash |
| token | 75 Sonnet | 4 Flash |
| — | CLI | |
| — |
1 DeepSeek API
DeepSeek 10
API KeysCreate API key sk- Claude Code DeepSeek
2
mkdir -p ~/.config/mg-deepseek && chmod 700 ~/.config/mg-deepseeksk-your-key-here
echo 'export DEEPSEEK_API_KEY="sk-your-key-here"' > ~/.config/mg-deepseek/key.env
chmod 600 ~/.config/mg-deepseek/key.env
source ~/.config/mg-deepseek/key.env700 600 API
3 Claude Code
Claude Code OAuth Vertex AIAWS Bedrock DeepSeek
cat > ~/.config/mg-deepseek/claude-deepseek-settings.json <<EOF
{
"env": {
"CLAUDE_CODE_USE_VERTEX": "",
"ANTHROPIC_VERTEX_PROJECT_ID": "",
"CLOUD_ML_REGION": "",
"ANTHROPIC_DEFAULT_OPUS_MODEL": "",
"ANTHROPIC_BASE_URL": "https://api.deepseek.com/anthropic",
"ANTHROPIC_AUTH_TOKEN": "$DEEPSEEK_API_KEY",
"ANTHROPIC_API_KEY": "$DEEPSEEK_API_KEY"
}
}
EOF
chmod 600 ~/.config/mg-deepseek/claude-deepseek-settings.jsonJSON
- ** 4 ** Vertex AI AWS Bedrock
ANTHROPIC_BASE_URLAPI DeepSeek Anthropichttps://api.deepseek.com/anthropicANTHROPIC_AUTH_TOKEN/ANTHROPIC_API_KEY
DeepSeek Anthropic API JSON Claude Code
4 Claude Code — DeepSeek
Claude Code DeepSeek
claude --bare \
--settings ~/.config/mg-deepseek/claude-deepseek-settings.json \
--model sonnet \
" Python JWT REST API"--bareClaude Code OAuth settings ——--settingsJSON- **
--model sonnet**Claude Code Anthropic DeepSeeksonnet→DeepSeek V4 Flash
Claude Code / /help``/bug``/review Claude Code
--bare | OAuth/ | ✅ |
--settings | DeepSeek JSON | ✅ |
--model sonnet | DeepSeek V4 Flash | ✅ |
**** DeepSeek V4 Pro DeepSeek API Claude Code Flash
5
API DeepSeek
claude --bare --settings ~/.config/mg-deepseek/claude-deepseek-settings.json \
--debug-file /tmp/check.log --model sonnet "SWAP_TEST"
grep "API REQUEST" /tmp/check.log | head -1/anthropic/v1/messages DeepSeek /v1/projects/.../publishers/anthropic/ Vertex AI—— settings JSON 4 bedrock-runtime AWS Bedrock——
| URL | ||
|---|---|---|
/anthropic/v1/messages | ✅ DeepSeek V4 | |
/v1/projects/.../publishers/anthropic/ | ❌ Vertex AI | JSON 4 |
bedrock-runtime | ❌ AWS Bedrock | JSON 4 |
6
** 1 — Claude CodeAnthropic / Vertex / Bedrock**
claude --model opus ""** 2 — DeepSeek **
claude --bare --settings ~/.config/mg-deepseek/claude-deepseek-settings.json \
--model sonnet " async/await "Claude Code settings
shell
# ~/.zshrc ~/.bashrc
alias claude-cheap='claude --bare --settings ~/.config/mg-deepseek/claude-deepseek-settings.json --model sonnet'claude-cheap ""→ DeepSeek V4 Flash 1 / tokenclaude ""→ Opus Sonnet
shell
Q1auth conflict
Claude Code OAuth --bare
Q2 Anthropic
--debug-file
claude --bare --settings ~/.config/mg-deepseek/claude-deepseek-settings.json \
--debug-file /tmp/check.log --model sonnet "test"
grep "API REQUEST" /tmp/check.logURL deepseek.com JSON shell
Q3 ANTHROPIC_BASE_URL `.zshrc
Claude Code Vertex/Bedrock --bare --settings
Q4 --model sonnet `--model opus
Claude Code Anthropic DeepSeek sonnet → DeepSeek V4 Flashopus → DeepSeek V4 Pro deepseek-v4 Claude Code
Claude Code``DeepSeek``Anthropic``Vertex AI``AWS Bedrock``OpenAI
Claude Code
Related tutorials
Claude Code Hub: Complete Knowledge Base for AI Coding with Anthropic's Agent
Claude Code is Anthropic's agentic AI coding tool that lives in your terminal. This hub organizes every tutorial, case study, comparison guide, and FAQ we have published about Claude Code — from your first install to advanced MCP server building and real-world revenue case studies. Whether you are new to AI coding or a veteran builder, this is your complete Claude Code reference.
DeepClaude Tutorial: Run Claude Code on DeepSeek in 15 Minutes
DeepClaude is a practical bridge from Claude Code to DeepSeek—setup and verify in about 15 minutes.
How to Build a Custom MCP Server for Claude Code: Step-by-Step Guide
If you want to build a custom MCP server so Claude Code can call your own tools — weather lookup, file summary, todo manager — this tutorial gives you a complete step-by-step guide with working Python code, JSON Schema tool definitions, and real API integration in under 45 minutes.
Topic hub
AI Coding Tools Hub (2026)
From Copilot pricing changes to Claude Code + DeepSeek cost-saving setups—one place to compare tools, read explainers, and follow tutorials.
Explore AI Coding Tools Hub (2026) →Monetization angle
How can you make money from this trend?
WayToClawEarn focuses on verified earn playbooks—not just news. Start from these cases.
DeepSeek + Claude Code Micro SaaS
Run multiple small products on cheap inference
Claude Code bug bounty
Productize agent skills into security services
Related tutorials
- GitHub Copilot Pricing 2026: Plan Comparison, Monthly Cost, and 3 Ways to Save
- How to turn off signature in VS Code Copilot AI: remove Co-Authored-by with one line of command
- Copilot vs Cursor vs Claude Code (2026): Which Should You Pick?
- DeepSeek Reasonix Tutorial: Build a Low-Cost Coding Agent in 30 Minutes
Related news
- DeepSeek Harness v0.2 Desktop Launch: Zero-Config AI Coding Agent, How to Choose?
- Google Gemini 4 Argon Released: 1M Output Tokens, DeepSWE SOTA — How It Compares for Coding and Cyber Defense
- OpenAI DevDay 2026: GPT-6.1 Sol at 1/5 Astra Price, Dots Autonomous Agent, Codex Cloud — What Developers Need to Know
- Plugin4Shell: Zero-click RCE hits four major AI coding agents — how to fix