Gemma 4 31B on Used RTX 4090 workstation (24 GB)

31.273B on 24 GB at 1,008 GB/s. Hardware details · Model details

CompatibilityDoes not fit
Fits
No
Calculated Requires more than 97% of usable memory. Needs a smaller quantization or more memory.
Recommended quantization
MLX 4-bit
Calculated mlx
Memory required
26.0 GB
Calculated of 22.1 GB usable — 118%
Max practical context
1K
Calculated model supports 256K

Memory budget at 8K context

Model weights
17.0 GB Calculated
KV cache
7.5 GB Calculated
Runtime overhead
1.5 GB Estimated
Total required
26.0 GB Calculated
Usable memory
22.1 GB Assumption
Headroom
-4.0 GB Calculated
No quantization in our catalogue fits this machine.
Discrete GPU: 24 GB of VRAM, of which we assume 92% is usable after driver and context overhead.
This model can be run with layers offloaded to system RAM, but decode throughput typically drops by an order of magnitude once any significant fraction of the weights crosses PCIe. We do not count offload as fitting.
PerformanceEstimated0/10
Decode (generation)
Estimated calculated, not measured
Prefill (prompt)
Estimated
TTFT at 8K
~1.9–3.9 s
Estimated time to first token
Power while generating
520 W
Measured
No throughput figures for this pairing. We do not estimate performance for a model that cannot load: a tokens-per-second number for a configuration that will never run is noise, not data. The alternatives below are machines that can actually run Gemma 4 31B.
How the estimate is calculated
  1. Decode: reading 31.3B active parameters at 4.50 bits/weight takes 21.81 ms at 1008 GB/s x 80% achieved efficiency.
  2. Prefill: 165 TFLOPS (FP16) x 4 for native FP4 tensor cores x 32% assumed model-FLOPs utilisation, divided by 2 x 31.3B parameters per token.

  • Prefill throughput is highly engine-dependent. Flash attention, batch size and quantized KV all move this number substantially, and for sparse mixture-of-experts models it is the least reliable figure we produce.
  • This is a calculated estimate, not a measurement. It assumes a single request, a short prompt, no speculative decoding and a warm model already resident in memory.

Estimator version estimator_v1. Stored with every estimated row so old estimates can be regenerated when the model improves.

This model at other quantizations on this machine
QuantizationWeightsTotal neededUtilisationFitMax context
MLX 4-bitrecommended17.0 GB26.0 GB118%Does not fit1K
Q4_K_M18.2 GB27.2 GB123%Does not fit152
Q8_031.6 GB41.0 GB186%Does not fit0
BF1658.3 GB68.5 GB310%Does not fit0
Cost of running Gemma 4 31B on this machineUnited States (federal) · C corporation · 8h/day
Monthly economic cost
$27
Calculated after tax
Codex/Claude Code
$100/mo
≈ $100/mo · local is $73 less
Net cash at purchase
$2,071
Calculated VAT not reclaimable
Total over 5 years
$1,611
Calculated after tax, after resale
Cost per USD/1M tokens
Calculated

The $100 comparison uses the Codex Pro 5x / Claude Max 5x plans. A fixed planning conversion is used for USD. This compares monthly spend only: subscriptions have usage limits, local hardware has different capabilities and constraints, and taxes or regional pricing may change the charged amount. Prices checked 7 September 2026.

Monthly breakdown

Depreciation
1,615 over 5 years, straight-line to a 456 residual
$26.92
Electricity
26.8 kWh/month at 0.140/kWh
$3.75
Cost of capital
4.0%/yr on 1,263 average capital employed
$4.21
Monthly cost before tax$34.88
Electricity tax shield
Running costs are deductible business expenses
−$0.79
First-year expensing
§179 (100.0%)
−$7.25
Monthly economic cost after tax$26.84

Three different numbers, deliberately

Cash cost
$2,071
Money that leaves the bank account on day one, net of reclaimable VAT.
Accounting depreciation
$26.92/month
$1,615 written down over 5 years to a $456 residual.
After-tax economic cost
$26.84/month
Depreciation plus running costs plus cost of capital, less the tax those deductions save. This is the figure to compare between machines.
Assumptions and sources (verified 2026-09-07)
VAT rate
0% Official spec
VAT recoverable
0% Official spec
Federal C-corporation estimate at the flat 21% rate. Pass-through entities should use the sole-proprietor estimate as a rougher proxy.
Effective deduction rate
21.00% Calculated
Headline marginal rate 21.00%.
Depreciation
5 years, straight-line Assumption
Residual value
$456 (22%) Assumption
Extrapolated.
Electricity
$0.140/kWh Assumption
Average power draw
152 W Calculated
Load 520 W for 20% of powered hours, idle 60 W for the rest — a machine that is on is not generating tokens the whole time.
Investment allowances
§179 100.0% Official spec
Worth $435 in total — first-year expensing that replaces later tax depreciation.
Cost of capital
$4.21/month Assumption
Federal planning estimate only, not tax advice. State and local income tax, sales/use tax and incentives are excluded. It assumes 100% business use, a Section 179 election, enough business income to use it, and that the full annual limit remains available.
Page quality score (why this page is or is not indexed)

6/13 marked noindex. Generated pages are gated so we do not ask a search engine to rank a page with nothing computed to say. The directive is emitted in the page head via the metadata API, not in the body, so it is authoritative.

  • Has a memory-fit calculation (+3)
  • Has a price (+2)
  • Has an ownership economics calculation (+2)
  • Well connected (18 internal links) (+1)
  • No benchmark or estimate
  • Model does not fit and there is no measurement to explain why it is worth knowing (-2)
  • Fails a hard requirement: an indexable page needs both a compatibility calculation and at least one benchmark or estimate.