MAI Code 2 Flash: Copilot Cost for Routine Coding
MAI Code 2 Flash is Microsoft’s lighter coding model for explanations, focused edits and fast iteration. GitHub Copilot lists promotional rates of $0.05 input and $0.25 output per million tokens. Microsoft also offers a limited-access Foundry preview with separate access and billing.
Content reviewed:
Check Code 2 Flash availability in Copilot ↗
Use this model
See access details in the guide below.
Use cases
- Explain an unfamiliar function without changing the repository.
- Repair a small defect with a regression test and a narrow diff.
- Run a batch of similar edits and track how often a change needs review or escalation.
Use Flash in Copilot or request Foundry access
GitHub lists Flash for Free, Student and paid Copilot plans, subject to account eligibility and organization model policy. Pick MAI Code 2 Flash in a supported Copilot client. For the first edit, specify the file, the expected behavior and the test to run. Review the diff for changes outside that scope.
Microsoft lists a limited-access Foundry preview for Flash. Check your Foundry account for access and deployment terms before planning a workload there. Copilot access and rates do not carry over to Foundry.
Microsoft also announced plans for OpenRouter, Vercel, Hermes, Open Code and Kilo. Those planned channels are not needed for the Copilot workflow above; confirm availability and billing on the channel you intend to use.
GitHub Copilot pricing: promotional and regular rates
For 100,000 uncached input tokens and 10,000 output tokens, the listed Copilot rates imply $0.0075 at the promotional rate or $0.015 at the regular rate. This is a fixed-usage calculation, not a separate API quote or a statement of what your subscription includes.
Check your plan’s included usage and model access. Add all requests in the session, including failed edits and repairs, when comparing costs.
GitHub tracks usage-based Copilot billing in AI credits, worth $0.01 each. Check your plan’s included credits and whether extra usage is enabled before treating the token estimate as an extra charge. If several developers share an organization budget, review credit use across their sessions rather than extrapolating from a single prompt.
| GitHub Copilot rate | Input / cache read / output per million tokens |
|---|---|
| Promotional | $0.05 / $0.005 / $0.25 |
| From May 17, 2027 | $0.10 / $0.01 / $0.50 |
Flash vs Code 2, GPT-6 Luna and Haiku 5.5
Microsoft reports comparable performance to GPT-6 Luna and Claude Haiku 5.5 at 65% and 20% of their costs, respectively, across three routine coding benchmarks. Those were maximum-effort runs in Copilot CLI without subagents, with Flash at its promotional rate. The tests do not measure service concurrency limits or predict cost on longer tickets.
For a batch of small fixes, record median and slow-tail completion time, tests passed and cost per accepted change. If a change requires tracing behavior across packages or designing an interface, retry with Code 2 and count the Flash attempt in the total.
For code explanations, give both models the same function and tests and ask each to identify the inputs, side effects and failure cases without editing files. Check the answer against the source before paying for a second pass. For repetitive edits, count patches that touch unrelated files as needing review even if their tests pass.
MAI-Code-1.1-Flash is a separate release with its own local build. The Code 2 Flash release paths here are hosted; do not use the older model’s local memory requirements to size this one.
Before you use it
- Microsoft’s limited preview announcement does not give a public Foundry rate for this model. Use the Copilot table only for that channel.
How to get started
Start with an explanation or a narrow edit and a test. Escalate work that repeatedly needs changes outside the requested scope.
Sources
Sources (3)
- Microsoft: Code 2 and Flash evaluations ↗
Source checked:
- GitHub: plans, client support and model policy ↗
Source checked:
- GitHub: promotional and regular token rates ↗
Source checked: