DeepSeek API Is No Longer Free: We Checked the Balance

Quick answer: DeepSeek's API is no longer free to start. We checked a real account on 2026-08-31: the balance endpoint reports granted_balance: 0.00 and any call returns 402 Insufficient Balance. The current models are V4-Flash and V4-Pro (V3/R1 were retired 2026-07-24), it's OpenAI-SDK compatible, and it remains among the cheapest frontier APIs once you top up — but you must top up first. Want DeepSeek models at $0? NVIDIA NIM hosts DeepSeek V4 Flash free.

DeepSeek is the budget pick among low-cost AI APIs: near-frontier quality at the lowest price, with a switchable "thinking" mode most rivals charge extra for. Below: the free trial, calling V4-Flash and V4-Pro in Python (chat, thinking mode, streaming, function calling), wiring it into OpenClaw, and how it compares to Gemini, Groq, and Alibaba Bailian.

Models & Pricing

ModelAPI NameContextBest For
DeepSeek-V4-Flashdeepseek-v4-flash1MGeneral chat, coding, high-volume tasks (default)
DeepSeek-V4-Prodeepseek-v4-pro1MAgents, math, complex step-by-step reasoning

Both models support a switchable thinking effort (low / high / max), so a single model can answer fast or reason deeply. The legacy deepseek-chat and deepseek-reasoner names were discontinued on 2026-07-24 — update any old code to the deepseek-v4-* IDs.

Details
Free trialNone — granted_balance is 0.00 on new accounts (checked 2026-08-31, re-checked 2026-09-01)
V4-Flash input / output~$0.14 / ~$0.28 per 1M
V4-Pro input / output~$0.435 / ~$0.87 per 1M
Prompt cachingCache hits ~98% cheaper than the standard input rate

At ~$0.14 per 1M input tokens vs $5.00 for GPT-4o a small top-up goes a long way — but you have to top up first; there is no starting balance. Prices shift — check DeepSeek's pricing page before you budget.

We checked: the free trial is gone

Plenty of guides — this one included, until we retested — say new DeepSeek accounts receive 5M free tokens for 30 days. We verified that against a real account on 2026-08-31. It does not hold.

A normal chat request returns:

HTTP 402
{"error":{"message":"Insufficient Balance","type":"unknown_error",
          "code":"invalid_request_error"}}

And the account's own balance endpoint confirms nothing was granted:

curl https://api.deepseek.com/user/balance   -H "Authorization: Bearer $DEEPSEEK_API_KEY"

{"is_available": false,
 "balance_infos": [{"currency":"CNY",
                    "total_balance":"0.00",
                    "granted_balance":"0.00",     <-- no free credit
                    "topped_up_balance":"0.00"}]}

granted_balance: 0.00 is the decisive field: it's where promotional credit would appear, and it's empty. Run that command against your own key before planning around a free tier — it takes one second and beats any blog post, including this one.

Where to get DeepSeek models for free instead

  • NVIDIA NIM hosts deepseek-ai/deepseek-v4-flash-0731 on its free tier, no card. We measured it at 27 tok/s — not fast, but free.
  • OpenRouter carries DeepSeek models, some with :free variants.
  • For raw speed on any free model at all, Groq ran 20× quicker in our cross-platform benchmark.

Getting an API Key

  1. Sign up at platform.deepseek.com and verify your email — no credit card.
  2. Open API Keys in the left sidebar, click Create new API key, and copy it.
  3. Add credit before your first call — new keys start at a 0.00 balance and return HTTP 402. (The chat app at chat.deepseek.com stays free for individual use.)

Using the API with Python

DeepSeek is fully OpenAI SDK-compatible — install openai, set the base_url, no separate package.

pip install openai

Basic chat (DeepSeek-V4-Flash)

from openai import OpenAI

client = OpenAI(
    api_key="YOUR_DEEPSEEK_API_KEY",
    base_url="https://api.deepseek.com"
)

response = client.chat.completions.create(
    model="deepseek-v4-flash",
    messages=[
        {"role": "system", "content": "You are a helpful coding assistant."},
        {"role": "user", "content": "Write a Python function to find all prime numbers up to N using the Sieve of Eratosthenes"}
    ]
)

print(response.choices[0].message.content)

Reasoning (DeepSeek-V4-Pro, thinking mode)

V4-Pro thinks before answering; read the chain-of-thought via reasoning_content, the final answer via content.

response = client.chat.completions.create(
    model="deepseek-v4-pro",
    messages=[
        {"role": "user", "content": "A train travels 120km in 1.5 hours, then 80km in 45 minutes. What is the average speed for the whole journey?"}
    ]
)

print("Thinking:", response.choices[0].message.reasoning_content)
print("Answer:", response.choices[0].message.content)

Streaming

stream = client.chat.completions.create(
    model="deepseek-v4-flash",
    messages=[{"role": "user", "content": "Explain how neural networks learn"}],
    stream=True
)

for chunk in stream:
    delta = chunk.choices[0].delta
    if delta.content:
        print(delta.content, end="", flush=True)

Function calling

Both V4 models support tool/function calling, making them a solid agent backend.

tools = [
    {
        "type": "function",
        "function": {
            "name": "get_weather",
            "description": "Get the current weather for a location",
            "parameters": {
                "type": "object",
                "properties": {
                    "location": {"type": "string", "description": "City name"}
                },
                "required": ["location"]
            }
        }
    }
]

response = client.chat.completions.create(
    model="deepseek-v4-flash",
    messages=[{"role": "user", "content": "What's the weather in Tokyo?"}],
    tools=tools,
    tool_choice="auto"
)

tool_call = response.choices[0].message.tool_calls[0]
print("Function called:", tool_call.function.name)
print("Arguments:", tool_call.function.arguments)

Connect DeepSeek to OpenClaw (Free AI Agent)

Pair DeepSeek with OpenClaw for a free autonomous agent that searches the web, runs code, manages files, and messages on WhatsApp or Telegram. Onboard the quick way:

npm install -g openclaw@latest
openclaw onboard

Choose OpenAI-compatible, enter https://api.deepseek.com as the base URL, and paste your key. Or configure manually in ~/.openclaw/openclaw.json:

{
  "models": {
    "mode": "merge",
    "providers": {
      "deepseek": {
        "baseUrl": "https://api.deepseek.com",
        "apiKey": "YOUR_DEEPSEEK_API_KEY",
        "api": "openai-completions",
        "models": [
          {
            "id": "deepseek-v4-flash",
            "name": "DeepSeek V4 Flash",
            "reasoning": false,
            "input": ["text"],
            "contextWindow": 1000000,
            "maxTokens": 8192
          },
          {
            "id": "deepseek-v4-pro",
            "name": "DeepSeek V4 Pro",
            "reasoning": true,
            "input": ["text"],
            "contextWindow": 1000000,
            "maxTokens": 8192
          }
        ]
      }
    }
  },
  "agents": {
    "defaults": {
      "model": {
        "primary": "deepseek/deepseek-v4-flash"
      },
      "models": {
        "deepseek/deepseek-v4-flash": {}
      }
    }
  }
}

Use deepseek-v4-flash for everyday tasks and switch to deepseek-v4-pro for complex multi-step problems.

DeepSeek vs Other Free AI APIs

FeatureDeepSeekGoogle GeminiGroqAlibaba Bailian
Best ModelDeepSeek-V4-ProGemini 2.5 ProLlama 3.3 70BQwen 3.6-Plus
Free TierNone (top-up required)Published limits withdrawn1,000 RPD / 200K TPD on the free models1M tokens/model
Paid PricingCheapest (~$0.14/1M)ModerateVery lowVery low
ReasoningYes (thinking mode)2.5 Pro (thinking)NoQwQ (limited)
Context Window1M1M128K1M
OpenAI CompatibleYesYesYesYes
SpeedModerateFastUltra-fastFast
MultimodalNoYesNoYes

When to Use It — and When Not To

Reach for DeepSeek when: you're coding or debugging (V4-Flash), solving math/logic step by step (V4-Pro), running cost-sensitive high-volume apps, migrating off OpenAI with zero code changes, or building tool-using agents.

Look elsewhere when:

  • You need multimodal — DeepSeek is text-only; use Gemini for image/audio/video.
  • You want a free tier at all — DeepSeek no longer has one; for ongoing free quotas look at Groq, or run DeepSeek models free on NVIDIA NIM.
  • You cannot prepay — access starts only after a top-up, though pricing stays very low.
  • Streaming with thinkingreasoning_content arrives before the final answer; handle both in your loop.

Frequently Asked Questions

Is DeepSeek free?

The chat app at chat.deepseek.com is free for individual use. The API is not: new accounts get no starting balance (granted_balance 0.00) and calls return HTTP 402 until you top up. Paid pricing is still very low — ~$0.14/1M input on V4-Flash, up to 30× cheaper than GPT-4o. (Verified 2026-09-01.)

Is it really OpenAI SDK-compatible?

Yes — install the openai package and point base_url at https://api.deepseek.com. It's a drop-in replacement with no code rewrite.

What's the difference between V4-Flash and V4-Pro?

V4-Flash (deepseek-v4-flash) is the fast, cheap default for coding and chat. V4-Pro (deepseek-v4-pro) is tuned for agents and reasoning. Both support a switchable thinking effort (low/high/max); in thinking mode they expose a chain-of-thought via reasoning_content before answering.

What happened to V3 and R1?

The V3 and R1 model names — and the deepseek-chat/deepseek-reasoner API aliases — were retired on 2026-07-24, replaced by the V4 line. Update any old code to deepseek-v4-flash or deepseek-v4-pro.

How does it compare to Groq and Gemini?

Groq is faster; Gemini wins on multimodal. But for the best mix of reasoning capability and cost, DeepSeek V4 leads on price among frontier APIs in 2026.

Get started: platform.deepseek.com