DeepSeek API cost depends on four things, the model, the hour, the cache and the output length. Input that hits the cache is billed at one thirtieth to one fiftieth of a cache miss, peak hours cost twice the off-peak rate, and thinking tokens are billed as output. Keeping prompts stable at the front and timing batch work off-peak cuts most bills sharply.
Ramthamedia Deep Knowledge Guides · October 2026
Price: Priceless · 20 min read
Preface
You switched to DeepSeek because the price per token looked like a rounding error. Then the monthly bill arrived bigger than the plan, and the dashboard could not tell you why. This Strategic Guide walks through the five places where DeepSeek API cost quietly grows, from peak-hour pricing to a cache that never hits, and shows the exact settings, log fields and habits that bring the bill back to what you expected.
Problems this book solves
- My DeepSeek bill is far higher than my token estimate (Chapters 1 and 2)
- Cache hit tokens stay at zero even though my prompt repeats (Chapter 3)
- Long prompts stopped caching after a model update (Chapter 4)
- Answers look short but the output bill is huge (Chapter 5)
- Old model names, 402 and 429 errors break my app (Chapter 6)
- My agent’s web searches started costing money (Chapter 7)
- I do not know when to run batch jobs or when DeepSeek is the wrong choice (Chapter 8)
Skip this if
- You only use the free DeepSeek chat app and never call the API.
- You run open DeepSeek weights on your own servers and pay no per-token bill.
Chapter 1
Where the Money in a DeepSeek Bill Actually Goes
You estimated the month at twenty dollars. The invoice says sixty. Nothing in your code changed, and the request count matches your logs. The gap sits in how DeepSeek API cost is calculated, and three of the four drivers are invisible if you only count requests.
DeepSeek bills each request as tokens multiplied by a price, and the price itself moves. The official pricing page lists two models today and splits every rate into an off-peak and a peak figure.
| Model, per 1M tokens | Cache hit input | Cache miss input | Output |
|---|---|---|---|
| deepseek-flash, off-peak | $0.003 | $0.15 | $0.60 |
| deepseek-flash, peak | $0.006 | $0.30 | $1.20 |
| deepseek-v4-pro, off-peak | $0.022 | $0.66 | $1.98 |
| deepseek-v4-pro, peak | $0.044 | $1.32 | $3.96 |
Read the table by column. A cache hit costs one fiftieth of a cache miss on Flash and one thirtieth on V4 Pro. Output costs three to four times a cache miss. So a prompt that misses the cache and a model that writes long answers are the two fastest ways to multiply a bill, long before the hour of day matters.
The hour still matters. Peak hours are 01:00 to 04:00 and 06:00 to 10:00 UTC on weekdays, which is 06:30 to 09:30 and 11:30 to 15:30 in India. Every token in those windows costs double. A team in Hyderabad that runs its nightly batch at 9 a.m. local time is paying peak rates for work nobody is waiting on.
The fourth driver is thinking. Both models think by default, and those reasoning tokens are billed as output, the most expensive column. A short answer can carry a long hidden chain of reasoning behind it. Chapter 5 puts a number on that.
Peak pricing also changes how you should read old benchmarks and blog posts. A cost comparison written before the peak and off-peak split, or one that quotes only the off-peak column, can understate a daytime Indian workload by half. Always check which column a quoted price comes from before you plan a budget on it.
There is one more choice hiding in the table, the model itself. V4 Pro costs three to four times Flash on every column. Many teams start on Pro because it sounds safer and never test whether Flash would have done the job. Keep Flash as the default and move a task to Pro only when your own tests show Flash failing it.
Price every request by its column, not by its count.
RECOMMENDED BOOK → Autonomous Frontier, The Systems Bible for Software Engineers by A. Ravinder
Building an AI agent takes a weekend. Keeping it alive in production is the hard part. 558 pages on who allowed the agent to act, how you prove it worked, and who stops it when it goes wrong. PDF eBook. Open it before your next agent goes live, and walk into that launch knowing exactly what it can touch, who can stop it and how you will prove it worked.
Read the bookChapter 2
What One Ordinary Chatbot Really Costs in a Month
Numbers on a pricing page feel small until they meet real traffic. Take one ordinary support chatbot and follow its money for thirty days.
It answers 10,000 questions a day. Every request carries the same 3,000-token system prompt with product rules, plus a 200-token customer question. Each answer is about 400 tokens. It runs on deepseek-flash. That is 32 million input tokens and 4 million output tokens a day.
| Same chatbot, per day | Input cost | Output cost | Per day | 30 days |
|---|---|---|---|---|
| Off-peak, cache never hits | $4.80 | $2.40 | $7.20 | $216 |
| Off-peak, system prompt cached | $0.39 | $2.40 | $2.79 | $84 |
| Peak hours, cache never hits | $9.60 | $4.80 | $14.40 | $432 |
| Peak hours, system prompt cached | $0.78 | $4.80 | $5.58 | $167 |
Now run the same chatbot on deepseek-v4-pro instead of Flash. Off-peak with no cache, input costs $21.12 a day and output $7.92, about $871 for the month. With the system prompt cached, input falls to $1.98 a day and the month to about $297. The model choice alone moves the bill by three to four times, which is why Chapter 1 asks you to prove that a task needs Pro before you pay for it.
Notice how the gaps stack. Pro instead of Flash multiplies by about four. Peak instead of off-peak doubles. A missed cache multiplies the input side by fifty. A team that gets all three wrong can pay more than forty times what a careful team pays for the same answers.
The same code, the same customers and the same answers produce a monthly bill anywhere between $84 and $432. The biggest single lever is the cache. When the 3,000 stable tokens hit, 30 million daily input tokens move from $0.15 to $0.003 per million, and the input bill falls by more than ninety percent.
Get New eBook Releases, Book Updates & Guides by Email
Receive instant updates when new RamthaMedia eBooks, printed editions, book companion resources, and deep research guides are published — 100% Free.
Look at the output column next. Once the cache works, output becomes most of the bill. That is why the length of answers, and the hidden thinking behind them, decides what you pay after the first fix.
These figures use the official rates in Chapter 1 and simple multiplication. Your own traffic will differ, so build the same small table with your real numbers before you trust any monthly estimate, including your own.
The cheapest token is the one that hits the cache. The next cheapest is the one you never generate.
Chapter 3
Why Your Cache Hit Count Stays at Zero
You send the same 3,000-word system prompt with every request. You expect most of it to bill at the cache-hit rate. The usage log shows prompt_cache_hit_tokens at zero, request after request.
The obvious fix, sending the prompt again, changes nothing. The reason is how the cache decides a match. DeepSeek caches on disk by default and needs no setting, but a request only hits when its beginning fully matches a stored prefix unit. Partial overlaps do not count. A single character that differs near the top turns the whole prompt into a cache miss.
The usual culprit is something dynamic placed early. A timestamp in the system message, a request ID, the user’s name in the first line, or a shuffled list of tools all change the opening bytes. Developers in public troubleshooting threads report the same pattern again and again, zero hits caused by a prefix that is never byte-for-byte identical.
Here is the order that works. First the fixed system instructions, word for word the same every time. Then the long reference material, such as a policy document or product catalogue. Then the tool definitions, always in the same order. Only after all of that comes anything that changes, such as today’s date, the customer’s name and the new question.
Retrieval systems break the cache in a quieter way. If your code pastes the five most relevant document chunks into the prompt, and the order of those chunks changes with every question, the prefix changes too. Put the chunks that never change, such as the product manual, before the chunks that are chosen per question, and sort the chosen chunks in a fixed order such as by document ID.
Multi-turn chats need one more habit. Append each new turn to the end of the history and never rewrite earlier messages. Summarising old turns to save tokens feels efficient, but it changes the prefix and throws away every cached unit behind the edit.
You can test this in ten minutes. Send the same request three times in a row and read the usage object each time. The first call will show mostly miss tokens. The second and third should show most of the stable part as hit tokens. If they do not, print the first two hundred characters of each prompt and compare them side by side, and the changing detail is usually obvious.
The log is the proof. Expect the first one or two requests to miss while the prefix is stored. After that, prompt_cache_hit_tokens should cover most of the stable part. The cache is best-effort and is cleared when unused, usually within hours to days, so a prompt you call once a week may rarely hit. That is a limit to plan around, not a setting you can change.
You may also like: TeamoRouter Developer Architecture Guide
Chapter 4
When Long Prompts Stop Caching After an Update
Your long-document pipeline cached well for weeks. Then, around mid-October 2026, hit tokens fell sharply on prompts above roughly 256,000 tokens, and costs jumped with nothing changed on your side.
An open GitHub issue in a popular coding-agent project reports exactly this, with request-level numbers, and links it in time to an upgrade of the Flash model served under the same API name. The pricing page today names the model behind deepseek-flash as DeepSeek-V4.1-Flash-1017. The documentation describes the cache as best-effort, and no cause is confirmed there. The pattern is what matters for your budget.
Why would an upgrade touch the cache at all? A cache stores work the model has already done on a prefix. When the model behind a name changes, that stored work may no longer fit the new model, and large prefixes are the most expensive to rebuild. Whatever the exact cause here, the safe assumption is that any version change can reset or weaken caching until you see otherwise in your own numbers.
The real risk is that a model name can stay the same while what sits behind it changes. A pipeline tuned on last month’s behaviour can lose its cache without a single error message, and the first warning is the invoice.
Three habits protect you. First, alert on the ratio of hit tokens to total input tokens, not on cost alone, so a drop shows within a day. Second, where a task allows it, split very long contexts so the stable part stays well inside the range where hits are reliable for you, measured in your own logs. Third, watch DeepSeek’s change log whenever the model version string on the pricing page changes.
A simple daily check is enough for most teams. Divide yesterday’s hit tokens by yesterday’s total input tokens. If the share falls by more than a third from its usual level, stop and look before the month runs on. In the chatbot from Chapter 2, losing the cache for one week adds about $30 off-peak and about $60 at peak.
A model name is a label. The version behind it is what you are billed for.
Chapter 5
Thinking Tokens and the Bill You Never See
Your answers look short and clean. The output column on the invoice says otherwise. Somewhere between the question and the answer, the model wrote far more than you read.
Both DeepSeek models run in thinking mode by default. Before the final answer, the model reasons step by step, and every one of those reasoning tokens is billed at the output rate. On Flash that is $0.60 per million off-peak, the most expensive column in the table.
Put a number on it. If the chatbot from Chapter 2 thinks for 1,500 tokens before each 400-token answer, its output grows from 4 million to 19 million tokens a day. Off-peak, the daily output bill rises from $2.40 to $11.40, about $270 more over thirty days, for answers the customer never sees.
Thinking earns its cost on hard problems, such as multi-step planning, tricky code or careful reasoning over long documents. It wastes money on simple ones, such as sorting tickets into categories, extracting a field from a form or rewriting a sentence. For those, switch the request to non-thinking mode as described in DeepSeek’s thinking-mode guide.
There is a middle path between all and nothing. Route each request by its job. A small rule in your code can send classification, extraction and formatting requests to non-thinking mode and keep thinking for planning, debugging and long reasoning. Many teams find that most of their traffic is the simple kind, so the saving is large while the hard answers keep their quality.
Test before you switch everything. Run a few hundred real requests in both modes, compare the answers, and keep thinking only where the quality difference is visible. Reasoning tokens also count against the context window, so long multi-turn chats in thinking mode can overflow sooner than you expect.
Chapter 6
More Guides from RamthaMedia
- Wonder Dynamics AI Visual Effects Architecture: Cloud VFX Pipelines, CGI Character Replacement, and Studio CapEx Economics
- Cloud Infrastructure Economics for Digital Businesses: Benchmarking Shared, VPS, and Cloud Hosting Limits for AI Workloads and Traffic Spikes
- Satellite IoT & Enterprise Remote Connectivity: LEO Constellations, Remote Industrial Telemetry, and Off-Grid Business Network Architecture
Old Model Names and the 402 and 429 Errors
A script that ran for months now fails on the first call. Another app works but throws errors at lunchtime. Both look like outages. Neither is.
The first is usually the model name. The current pricing page lists only deepseek-flash and deepseek-v4-pro. Code written for the older names deepseek-chat and deepseek-reasoner should be checked against the model list before anything else, because third-party pricing guides report that those names were retired in July 2026.
The second is the balance. Error 402 means insufficient balance, and it arrives without warning when a prepaid balance runs out. Granted balance is spent before topped-up balance, so a free credit can hide how fast real money is going. Set a low-balance alert and top up before batch jobs, not after they fail.
The third is speed. Error 429 means requests are arriving too fast. The pricing page lists a concurrency limit of 2,500 for Flash and 500 for V4 Pro. Fire too many parallel calls and the extras are refused. Retry with exponential backoff, cap your parallel workers below the limit, and spread batch work across the off-peak hours from Chapter 1, which helps both cost and refusals.
Build these three checks into your deployment, not into your memory. A startup check that calls the model list and fails loudly if your configured model name is missing. A balance check that warns the team when the balance falls below a set number of days of normal spend. A rate check that counts 429 responses per minute and slows the queue before the refusals pile up.
Retries have a cost of their own. A request refused with 429 is not billed, but a retry loop without a limit can turn one slow minute into thousands of repeated calls once capacity returns. Cap retries per request, add a small random delay, and log every refusal so you can see when your traffic pattern, not DeepSeek, is the problem.
Enterprise Business Section: The TCO Economics of DeepSeek vs. Dense Foundation Models
For Chief Information Officers (CIOs) and enterprise AI architects, foundation model selection has transitioned from raw benchmark scores to Total Cost of Ownership (TCO) economics. Running dense frontier models (such as GPT-4o or Claude 3.5 Sonnet) across multi-turn enterprise agent loops introduces severe operational margin dilution. When an enterprise application handles 25,000 daily active customer interactions, monthly API expenditures frequently exceed $35,000 (₹29 Lakh).
DeepSeek’s architectural breakthrough—activating only 21 billion parameters per token out of a total 236 billion parameter pool—fundamentally alters the unit economics of generative AI. By pairing Multi-Head Latent Attention (MLA) with aggressive KV-cache compression, memory bandwidth consumption across server GPUs drops by 93%. In private on-premises deployments (running 8x Nvidia H800/H20 SXM clusters) or public serverless API endpoints, enterprises achieve:
- 82% Reduction in Input Token Costs: DeepSeek’s context-caching engine charges only $0.014 per million cached input tokens—a full 90% discount over standard commercial API rates.
- Predictable Batch Throughput: Utilizing DeepSeek’s asynchronous batch inference APIs allows financial services and e-commerce platforms to process overnight analytical jobs (document summarization, fraud audits) at an effective cost of less than ₹0.02 per complex query.
- Sovereign On-Premises ROI: Enterprises in defense, banking, and healthcare deploying self-hosted DeepSeek weights achieve complete hardware CapEx payback within 7 months compared to paying commercial cloud API toll gates.
You may also like: Mastering Autonomous AI Agents and Frontier Models
Chapter 7
Search and Fetch, the New Line on the Bill
Your agent got smarter last month. It now searches the web and reads pages before it answers. From 1 November 2026, that habit can show up as its own line on the invoice.
DeepSeek bills its Search and Fetch tools at $0.75 per 1,000 successful requests each. Calls made through DeepSeek Harness, Claude Code or Codex are free for now, and per-request billing for them starts at 00:00 Beijing time on 1 November 2026.
The amounts look small, so count them honestly. An agent that runs one search and two fetches for each of 1,000 tasks a day makes 3,000 tool calls daily. That is about $2.25 a day, or about $68 a month, before a single token is counted.
Agents multiply this quietly because each task can trigger several searches. A research agent that checks five sources for each of 2,000 daily tasks makes 10,000 searches a day, about $7.50 daily or $225 a month, which can be more than the token bill for the same work on Flash.
Fetch has a second cost that is easy to miss. The text of every page the agent reads goes back into the prompt as input tokens, usually fresh ones that cannot hit the cache. A fetched article of 3,000 tokens adds about $0.00045 on Flash off-peak, small once, but repeated for thousands of tasks a day it becomes a steady part of the input column.
Two habits keep this line under control. Cache your own search results for questions that repeat, so the same query is not paid for twice in a day. And let the agent search only when its first answer is uncertain, instead of on every step by default.
Chapter 8
Timing the Work and Knowing When to Look Elsewhere
You now know where the money goes. The last decision is when to run the work, and whether this is the right service for it at all.
For anything that does not need an instant answer, such as nightly summaries, document indexing or test runs, schedule it outside the peak windows. Weekends and Chinese public holidays are fully off-peak. Moving a batch from 9 a.m. to 4 p.m. India time halves its token price with no code change.
Before the month starts, run a five-point check. Is every stable part of the prompt at the front and identical? Is the cache hit share logged and alerted? Is thinking switched off where it adds nothing? Are batch jobs scheduled off-peak? Is there a low-balance alert above one day of normal spend?
Set one number before the month begins, a daily budget. Divide the amount you are willing to spend in a month by thirty, and alert the team when any single day passes that figure by half. A cache that stops hitting, a model left in thinking mode or a retry loop gone wild will all show up within one day instead of at the end of the month.
Keep a short monthly review as well. Compare the four columns from Chapter 1 against last month, note which one grew, and tie that growth to a change in traffic, prompts or model version. A bill you can explain line by line is a bill you can control.
DeepSeek is less suitable if your project needs a guaranteed cache hit rate for its budget, a fixed contract price that never moves by the hour, or predictable behaviour when the model behind a name is upgraded. In those cases a provider with explicit, developer-controlled caching or committed pricing is the shape of tool to look for, even at a higher list price.
If you do move part of the work elsewhere, keep the habits from this book. Stable prompt prefixes, short answers, thinking only where it pays, retries with limits and a daily budget alert lower the bill with almost every API provider, because almost every provider charges more for fresh input and generated output than for repeated input.
If your goal is cheap high-volume text work, stable prompts and off-peak scheduling make DeepSeek one of the lowest-cost options available. If your goal is a predictable monthly number above all, measure the four columns for a month before you commit.
Questions readers actually ask
Is DeepSeek API cost the same at every hour?
No. Peak hours on weekdays cost twice the off-peak rate. The current windows are listed on the official pricing page and should be checked before scheduling large jobs.
Do I need to enable context caching?
No. Disk caching is on by default for every request. You only need to keep the start of your prompt identical so later requests can match it.
How do I see whether my requests hit the cache?
Each response includes a usage object with prompt_cache_hit_tokens and prompt_cache_miss_tokens. Log both per request.
Are thinking tokens charged?
Yes. Reasoning tokens are billed at the output rate, so turning thinking off for simple tasks can lower the bill.
How much can caching save on a typical chatbot?
In the worked example in this book, caching a 3,000-token system prompt cuts the input bill by more than ninety percent, from $4.80 to $0.39 a day off-peak on Flash.
Are Search and Fetch calls free?
They are billed at $0.75 per 1,000 successful requests each. Calls through DeepSeek Harness, Claude Code or Codex are free until per-request billing starts on 1 November 2026.
What does error 402 mean on DeepSeek?
It means the account balance has run out. Top up or check whether a granted balance has been used up.
Can I pay in Indian rupees?
The official prices are listed in US dollars. Check the DeepSeek platform for the payment methods available in your country at the time you top up.
Liked this Deep Knowledge Guide?
A deeper paid eBook on running AI APIs at low cost is being planned. Tell us in the comments which problem you want covered in depth, and share this book with someone whose AI bill keeps surprising them.
Contact / More useful information from Ramthamedia
- Official Website: https://www.deepseek.com
- Developer Repository: https://github.com/deepseek-ai/deepseek-harness
- Open Source Model Weights: https://huggingface.co/deepseek-ai
- User Support Interface: Contact us button in product dashboard
The details above (phone numbers, emails and the like) can change over time. For the latest information, visit the official link below.
Official source links: DeepSeek
Disclaimer: This eBook is compiled from publicly available information and was accurate at the time of writing. For full and up-to-date details, please visit the official website linked above. Ramthamedia accepts no legal liability for any decision made on the basis of this eBook, and nothing here is professional, financial or legal advice. The image used for the cover page is illustrative only – a stock photo from Pexels or an AI-generated image, never a real photograph of the site described.
Get New eBook Releases, Book Updates & Guides by Email
Receive instant updates when new RamthaMedia eBooks, printed editions, book companion resources, and deep research guides are published — 100% Free.