Getting a DeepSeek API Key
DeepSeek's API is famously cheap, and the key takes a couple of minutes. Here's the path, one compliance caveat that matters for EU/enterprise, and a zero-retention way to call it.
Step by Step
- Go to platform.deepseek.com and register.
- Open the API keys section and click Create new API key. Copy and store it securely (shown once).
- Top up a small balance under Billing — DeepSeek is pay-as-you-go and extremely cheap.
- DeepSeek is OpenAI-compatible, so most OpenAI SDK code works by swapping the base URL and model string.
The One Caveat: Data Residency
DeepSeek's official API processes data on servers in China. For EU/PII or enterprise-compliance workloads that's a real consideration (GDPR). Two clean options:
- Self-host the open weights (DeepSeek V4 is MIT-licensed) on your own infra, or
- Call DeepSeek through a zero-retention gateway. LinkModel runs DeepSeek behind one key with zero data retention by default, up to 30% below official:
curl -X POST https://api.linkmodel.ai/v1/chat/completions \
-H "Authorization: Bearer $LINKMODEL_API_KEY" -H "Content-Type: application/json" \
-d '{ "model": "deepseek-v4-flash", "messages": [{"role":"user","content":"Classify these tickets: ..."}] }'Also note: DeepSeek's legacy aliases retire July 24, 2026 — use deepseek-v4-flash / deepseek-v4-pro. Confirm the chat endpoint in the docs.
Which DeepSeek Model
- Cheapest, high-volume, cache-heavy → DeepSeek V4 Flash ($0.14/$0.28, 98% cache discount, 1M context)
- Competition-grade coding / deep reasoning → DeepSeek V4 Pro
When each wins: DeepSeek Pro vs Flash. Free-usage tips: how to use DeepSeek API free.
Keep the Bill Near Zero
DeepSeek's automatic prefix caching cuts repeated input ~98%. Structure prompts as [stable prefix] + [variable input] — see prompt caching.
Bottom Line
Get a DeepSeek key at platform.deepseek.com and top up — it's the cheapest capable API around. For EU/enterprise, self-host or call it through a zero-retention gateway. Need OpenAI/Gemini/Claude too? See how to get an API key.
Start free with a $1 credit and call DeepSeek with zero data retention.
