How much does a code review cost?
Take a review with 12,000 input tokens, of which 8,000 are cached, and 1,500 output tokens. The Code reviews example repeats that request 1,000 times. During the promotional period the three charges are $0.20 for uncached input, $0.04 for cached input and $0.375 for output. Together they come to $0.615. Under the next published schedule the same workload comes to $1.23.
Use the request count for the period you are estimating. If your tests average 25 calls per weekday over 20 weekdays, enter 500 requests. If a code review makes several model calls, count each call separately. The output is an estimate of model usage in US dollars. Plan fees, included credits, taxes and separate services can affect the amount you pay.
Where the rates come from
Microsoft introduced MAI Code 2 Flash on November 17, 2026. GitHub publishes separate rates for input, cached input and output. The calculator uses the selected usage date to choose the published schedule. Split a workload across two estimates if it spans the change on May 17, 2027. GitHub model pricing · Microsoft's launch announcement
Using your own token counts
Enter the total input including the cached portion. For example, if a usage record reports 4,000 uncached input tokens and 8,000 cached tokens, enter 12,000 and 8,000 respectively. The calculator subtracts the cached tokens before pricing the remaining input. If you have no recorded cache hits, start at zero and compare a second scenario after you measure them. Token worksheet and worked example
The output total includes all billable output tokens in your usage record. The CSV preserves the rate schedule, token amounts, request count and calculated costs, including small values that are rounded on screen. Current rates and effective dates
Does the calculator call the model?
The calculation runs in your browser. It accepts token counts only and requires no prompt, code, API key or account. A meaningful choice between models also depends on whether they finish your task correctly. Compare Flash and MAI Code 2 on the same workload