DeepSeek V4 Flash Price vs Self-Hosted SGLang: Cost per Request

DeepSeek V4 Flash price, dated, set against self-hosted SGLang cost per request at a fixed p95, with a worked two-config comparison and break-even rate.

DeepSeek V4 Flash Price vs Self-Hosted SGLang: Cost per Request
Written by TechnoLynx Published on 11 Jul 2026

As of October 2026, the DeepSeek V4 Flash price on DeepSeek’s own API is $0.30 per million input tokens and $1.20 per million output tokens at peak, and $0.15 and $0.60 at all other hours. Input that hits DeepSeek’s context cache costs $0.006 per million tokens at peak, roughly 98% below the cache-miss rate. Self-hosting DeepSeek on SGLang beats those rates only if the configuration that is cheap per token also meets the p95 latency your product needs, at the utilisation you actually run. LMSYS’s figure of $0.20 per million output tokens fails that test: it comes from a deployment whose latency, by LMSYS’s own account, needs further optimisation for real-time use.

There is a naming gap to keep in mind. The SGLang serving measurements cited here are for DeepSeek-V3, while the API price is for V4-Flash, a different model with 284 billion total parameters and 13 billion active per forward pass; the V4-Flash figures here are API prices, not serving measurements.

DeepSeek V4 Flash Price as of October 2026, and How It Has Moved

DeepSeek has changed the rate card more than once in 2026, so every price in a business case needs a date. Peak hours are 01:00 to 04:00 and 06:00 to 10:00 UTC, Monday to Friday, excluding Chinese public holidays. Every other hour, including weekends and those holidays, is billed at 50% of the peak rate.

Period Input (cache miss) Input (cache hit) Output
Until 16 August 2026, 16:00 UTC (flat) $0.14 $0.0028 $0.28
From 16 August 2026, peak $0.30 $0.006 $1.20
From 16 August 2026, off-peak $0.15 $0.003 $0.60

The rows above come from one pricing tracker’s dated V4-Flash prices. The same tracker notes that DeepSeek’s pricing page now lists the model as DeepSeek-V4.1-Flash, and that it earlier showed $0.44 and $1.32 at peak before the current repricing. A second pricing source gives the same peak windows and the same off-peak input rate.

Some properties of the API matter more for cost per request than the headline rate:

  • Billing is per token only. There is no per-request fee, monthly minimum or seat charge. Cost per request on the API is input tokens times the input rate plus output tokens times the output rate.
  • The peak surcharge is small for evenly spread traffic. Peak covers 35 of the week’s 168 hours, so a workload spread evenly across the week pays about 21% more than the pure off-peak rate.
  • Concurrency is capped. An account can hold 2,500 concurrent requests on deepseek-flash, and going over returns HTTP 429. Raising the cap means asking DeepSeek for more capacity.

How Does SGLang Serve DeepSeek-V3, and What Does That Mean in Practice?

SGLang serves DeepSeek-V3 as a sparse Mixture-of-Experts model, and part of its DeepSeek-specific work is aimed at allowing larger batches. Each token goes to one shared expert and 8 routed experts. In the V3/R1 architecture that means 37B of 671B parameters are active per token. Multi-head Latent Attention (MLA) caches a compressed latent vector instead of full per-head keys and values. That takes DeepSeek-V3’s KV cache to 70 KB per token, against 516 KB for Llama-3.1 405B, and a smaller KV cache leaves room for much larger batches.

DeepSeek models use MLA with a single KV head, so tensor parallelism across 8 GPUs duplicates the KV cache. SGLang therefore runs attention data-parallel, and in v0.4 that gave 1.9× the decoding throughput of v0.3. Multi-node deployments add prefill-decode disaggregation and large-scale expert parallelism, using DeepSeek’s DeepEP communication library, the DeepGEMM grouped-GEMM kernels and two-batch overlap to hide communication behind compute. Prefill is compute-intensive and decode is memory-intensive, which is why splitting them onto separate pools pays off. We cover the algorithmic side in how DeepSeek inference drives GPU cost and the multi-node layout in SGLang expert parallel serving and what profiling reveals.

In practice, cost per request on SGLang is mostly decided by how large a batch you can keep running, and latency is what that batch size costs you. Production cost and latency can often be improved through batching, caching, routing, quantisation and serving configuration, all of which sit below the model layer and can be tuned on their own.

How Do You Set up SGLang to Serve DeepSeek-V3, and What Serving Parameters Affect Cost per Request?

The flags that move cost per request are the ones that set parallelism, KV cache capacity and how prefill shares GPU time with decode. A minimal single-node launch looks like this:

python -m sglang.launch_server \
  --model-path deepseek-ai/DeepSeek-V3 \
  --tp 8 \
  --mem-fraction-static <tuned value> \
  --chunked-prefill-size <tuned value>
  • Quantisation. The official DeepSeek-V3 checkpoint is already FP8, so do not add --quantization fp8 when serving it.
  • Parallelism. --tp sets tensor parallelism and --dp adds data-parallel replicas. SGLang’s documentation says data parallelism is better for throughput when memory allows.
  • KV cache pool. --mem-fraction-static is the share of GPU memory given to model weights plus the KV cache pool. Set it as high as possible for concurrency while leaving room for activations and CUDA graph buffers. The documentation’s rule of thumb is 5 to 8 GB for activations. If you hit out-of-memory errors during serving, lower it.
  • Prefill chunking. --chunked-prefill-size caps the tokens per prefill chunk, and -1 turns chunking off. --max-prefill-tokens defaults to 16,384.
  • Streaming and decode steps. A larger --stream-interval raises throughput at the cost of smoother streaming. Running several decode steps per scheduling round can also raise throughput, but may increase time to first token.
  • Speculative decoding. On H200 with TP8, EAGLE speculative decoding sped up decoding by up to 1.8× at batch size 1 and 1.5× at batch size 32. DeepSeek reports that its Multi-Token Prediction module accepts the second predicted token 80% to 90% of the time, for 1.8× generation speed. The gain shrinks as batch size grows, so whether it lowers cost per request depends on the concurrency you settle on.

What Self-Hosting V4-Flash Would Take in Hardware

The two sources disagree on the hardware V4-Flash needs. One pricing tracker lists 140 to 158 GB of VRAM and a minimum of two 80 GB H100s. The model listing says the native FP4 plus FP8 build (about 146 GB on disk) needs B200 GPUs for its FP4 expert weights, and the FP8-only build for H100 is about 284 GB. 284 GB of weights cannot fit in two 80 GB cards (160 GB in total), so we read the two-H100 figure as wrong for the H100-compatible build. Four H100s (4 × 80 GB = 320 GB) would leave only about 36 GB beyond the 284 GB of weights for KV cache and activations.

How Do RadixAttention, Continuous Batching, and Concurrency Settings Change Cost-per-Token for DeepSeek-V3 on SGLang?

On self-hosted hardware, cost per million tokens equals the hourly cost of the hardware divided by sustained tokens per second times 3,600, times one million. Each one’s benefit depends on the workload, so you have to measure it on yours.

RadixAttention keeps the KV cache of prompts and generations in a radix tree instead of throwing it away, so later requests that share a prefix skip recomputing it. LMSYS’s ablation found no noticeable overhead even without cache hits, and particularly strong first-token latency when a prefix hits the cache. The headline “up to 5× higher throughput” came from Llama-7B and Mixtral-8x7B on A10G GPUs, measured against Guidance and vLLM. It is not a DeepSeek figure. How much RadixAttention saves on your traffic depends on your prefix overlap ratio. A system prompt reused across calls is one example of a shared prefix.

The API changes this comparison because DeepSeek’s API already prices prefix reuse. The cached input rate is about 98% below the cache-miss rate. A workload with 90% cache hits on V4.1-Flash pays an effective off-peak input price of about $0.018 per million tokens. For reference, DeepSeek reported that 56.3% of its own V3 and R1 input tokens hit its on-disk KV cache over one 24-hour window in February 2025. On the API, every request gets prefix caching automatically. On the API the saving goes straight to your bill. On your own GPUs, RadixAttention retains the KV cache of prompts and generations for reuse across requests. SGLang’s cache-aware load balancer reported up to 1.9× throughput and a 3.8× higher hit rate across workers.

Continuous batching helps decode far more than prefill. Decode is memory-bound and gains a lot from batching, while prefill is compute-bound and gains little. Mixing the two phases forces a trade between throughput and latency, and schedulers that prioritise prefill can stall token generation for several seconds. The Sarathi-Serve authors set the prefill token budget by profiling batches and picking the largest size that does not break the time-between-tokens SLO. With a 512-token budget under a strict SLO, they measured 3.5× the serving capacity of vLLM on Mistral-7B. For tuning chunked prefill and the scheduler, see SGLang scheduling and cost per request.

Concurrency sets the operating point. More concurrent requests fill larger batches and raise throughput, but batching prefills with decodes trades throughput against latency. For MoE models, the batch size needed to keep the expert layers compute-bound depends only on the model and the accelerator. Once batches are large, interconnect bandwidth and expert load imbalance dominate MoE communication time.

How Do You Benchmark DeepSeek-V3 on SGLang at a Fixed p95 Instead of Tokens per Second?

Fix the latency percentile first, then find the cheapest configuration that stays inside it. A throughput counter cannot tell you that, because it has no latency attached. SGLang’s documentation makes bench_serving the default tool. It is an async HTTP client that sends requests at controlled rates and concurrency to a running server, and it reports time to first token (TTFT), time per output token (TPOT), inter-token latency (ITL) and throughput. The same documentation warns that bench_one_batch_server never reaches steady state, so its metrics are biased. bench_offline_throughput measures the maximum throughput with no HTTP layer. That makes it a useful ceiling, but it is not a serving cost.

The sweep runs in this order:

  1. Write the SLO as a percentile on named metrics. For example, p95 TTFT and p95 ITL, on the latency your product’s users actually feel.
  2. Freeze the request distribution. Use the same dataset and input and output lengths in every run. SGLang’s own DeepSeek-V3 benchmarks use ShareGPT conversations, set to 1,024 input and 1,024 output tokens.
  3. Run each concurrency level to steady state. Use at least five prompts per unit of maximum concurrency.
  4. Record request throughput and the SLO percentiles for each configuration, and drop every configuration that misses the SLO.
  5. Price the survivors. Cost per request is the hardware cost per hour divided by requests per second times 3,600. The highest load that meets the latency targets is what Sarathi-Serve’s authors call capacity, and higher capacity lowers serving cost.

Before you put a cost gap down to a flag, profile what the GPUs are doing in each configuration. Context from profiling beats rules of thumb when deciding which lever matters. Our guide to profiling GPU kernels to find the real bottleneck covers that step. The general cost-per-request benchmarking method lives on its own page. Standard suites such as MLPerf Inference report a real, auditable number, but it is not your cost per request.

What Does a Worked Comparison of Two SGLang DeepSeek-V3 Configs Look Like?

SGLang’s DeepSeek-V3 documentation publishes two bench_serving runs, one at concurrency 1 and one at a maximum concurrency of 100. Pricing both against the V4-Flash rate card shows how the comparison works. These are the assumptions, stated as assumptions. Both runs are priced as one 8-GPU node, although the cited outputs do not state the hardware they ran on. The hourly rate borrows DeepSeek’s own disclosure, which assumed $2 per H800 GPU-hour. At 8 GPUs that gives $16 per node-hour (8 × $2). This is a rate for the arithmetic, not a quote for any GPU’s capacity.

  Config A (latency-sensitive run, concurrency 1) Config B (max concurrency 100)
Request throughput 0.12 req/s 2.46 req/s
Output token throughput 34.26 tok/s 463.80 tok/s
Tokens per request (in / out) about 202 / 286 (24.27 ÷ 0.12, 34.26 ÷ 0.12) about 302 / 188 (301,701 and 188,375 tokens over 1,000 requests)
Latency reported none in the cited output median TTFT 476.80 ms, P99 TTFT 8,329.50 ms, P95 ITL 398.60 ms
Requests per node-hour 0.12 × 3,600 = 432 2.46 × 3,600 = 8,856
Self-hosted cost per request at $16/node-hour $16 ÷ 432 ≈ $0.037 $16 ÷ 8,856 ≈ $0.0018
V4-Flash API, same token mix, peak 202 × $0.30/M + 286 × $1.20/M ≈ $0.00040 302 × $0.30/M + 188 × $1.20/M ≈ $0.00032
V4-Flash API, same token mix, off-peak ≈ $0.00020 ≈ $0.00016

The table makes three points. Raising concurrency cut the priced cost per request about 20-fold (8,856 ÷ 432), at the same assumed node rate. The cheaper config costs latency: its P95 inter-token latency is 398.60 ms and its P99 TTFT is over 8 seconds. If your p95 ITL budget is tighter than 398.60 ms, Config B’s per-request price is not one you can use. Even Config B, at the assumed rate, costs about 5.7 times the V4-Flash peak price for the same token mix (0.0018 ÷ 0.00032). The break-even node rate for Config B against API peak pricing is 8,856 × $0.00032 ≈ $2.81 per node-hour.

The two runs also produced different request shapes, even though the benchmark was set for 1,024-token inputs and outputs. Because the two runs’ token mixes differ, the API column re-prices each run’s own mix instead of assuming one. This example is not a verdict on V4-Flash self-hosting. V4-Flash activates 13B parameters per forward pass, against 37B per token for V3. That has not been measured here, and on your hardware it is the number you would need to measure.

Where Does a Throughput-Optimal SGLang Config for DeepSeek-V3 Stop Mapping to Margin?

One published SGLang cost figure for DeepSeek comes from a deployment built for throughput, and its latency shows the trade. LMSYS ran DeepSeek-V3 on 12 nodes of 8 H100 GPUs, with prefill-decode disaggregation and large-scale expert parallelism, and reached 52.3k input and 22.3k output tokens per second per node for 2,000-token inputs. That works out to $0.20 per million output tokens, which LMSYS put at about one-fifth of the official DeepSeek Chat API price. The setup improved output throughput by up to 5× over vanilla tensor parallelism on the same hardware. As a check, 22,300 tokens per second times 3,600 is about 80.3 million output tokens per node-hour, and $16 divided by that is about $0.20 per million.

Against today’s price card, $0.20 is a sixth of the V4-Flash peak output rate and a third of the off-peak rate. The same post reports TTFT of 2 to 5 seconds and inter-token latency of about 100 ms, and says further optimisation is needed for real-time use.

A throughput-optimal config stops paying for itself in four situations:

  • The SLO is tighter. The operating point that produced $0.20 had a TTFT of 2 to 5 seconds, too slow for a sub-second first-token budget.
  • Utilisation falls. Self-hosted node-hours cost the same whether they serve tokens or not. DeepSeek’s own fleet averaged 226.75 nodes against a peak of 278 over one day. Our page on how cost depends on load and SLO works through utilisation-aware cost curves.
  • Prefix overlap is high. The API’s 98% cached-input discount then competes directly with whatever RadixAttention saves you.
  • Traffic can move off-peak. Half-price hours cut the API side of the comparison, and self-hosted hardware gets no such discount.

How Do You Turn the SGLang DeepSeek-V3 Benchmark into a Serving-Config Decision You Can Defend?

The SLO, utilisation, prefix overlap and time of day each decide which path is cheaper, so each has to be measured.

If your measurements show… Then the cheaper path is likely…
Cost per request at your p95 below the dated API price for the same token mix, at realistic utilisation Self-hosted SGLang, with the winning config written down
Cost per request below the API only at a concurrency that breaks your p95 The API, or a self-hosted config tuned for the SLO (a re-run, not the headline config)
High prefix reuse or traffic that can move off-peak The API, whose cache and off-peak rates already price those patterns

The rows are our judgement, and the table holds only when every row is measured on the same request distribution. On both paths, the serving levers come before a model swap. Changing the model is the most expensive lever, and it often leaves the workload economics unchanged. For the vLLM-versus-SGLang side of the same question, see what the SGLang runtime choice costs and saves.

Who Can Tell Us Whether Our DeepSeek Serving Path Beats the API Price?

TechnoLynx’s Inference Cost-Cut Pack audits a production DeepSeek serving path and measures its cost per request at the p95 your product needs, so the API-versus-self-host decision rests on your numbers instead of a published throughput record. The work starts with an audit of the deployed serving path. It then runs the comparison across your candidate batching and concurrency settings and ends with cost-per-request numbers before and after the changes. We look for cost and latency improvements in the serving path before recommending a model replacement. This sits within our work on AI for AI infrastructure and production SaaS.

The engagement does not suit everyone. If your volume is modest and spread over the day, the dated V4-Flash rate card is probably the whole answer, and there is no serving path to tune. A team that already runs SGLang can do a first pass itself with bench_serving and the steady-state rule in SGLang’s documentation.

The Number to Settle Before Choosing

In the worked example that came to under $3 per node-hour against peak pricing, well below the $16 rate assumed there. What remains unmeasured is how V4-Flash, with fewer active parameters than V3, performs on your own hardware.