Microsoft MAI Code 2 in 2026: Pricing, GitHub Copilot & the Claude Comparison

Microsoft dropped a bomb on the coding world on November 17, 2026, and I almost missed how big it was. MAI Code 2 — the company’s first flagship coding model built entirely in-house — went live in GitHub Copilot the same day it was announced, with a price tag that reads like a typo: $0.50 per million input tokens and $2.50 per million output tokens. Next to Claude Opus 5.5 at $4 and $20, that’s not a discount, that’s a different league.
But here’s the thing I learned after digging through Microsoft’s announcement, the model card, and GitHub’s pricing docs: the headline numbers come with a catch, and the catch has a date on it. This article is the honest version — what MAI Code 2 costs, what it can actually do, where it beats Claude, and where it quietly loses.
Quick note before we start: there are no affiliate links in this article. Microsoft offers no affiliate program for MAI Code 2, GitHub Copilot, or Azure AI, so there’s nothing to earn here — just the facts as I found them. Prices checked November 21, 2026.
The short version
MAI Code 2 is Microsoft’s new agentic coding model, launched November 17, 2026 at Microsoft Ignite. It lives inside GitHub Copilot — that’s the only place you can use it right now. On Microsoft’s own benchmarks it scores about 96% of Claude Opus 5.5’s performance at roughly 5% of the cost per task, and 98% of GPT-6.1 Sol at 40% of the cost. Those cost claims are real, but they’re calculated at a 50% launch price that ends on May 17, 2027, when every rate doubles. At full price it’s still about a tenth of Opus 5.5’s cost per task — which is still a big deal — but the “5%” number you keep seeing only holds until that date. My verdict: if you already pay for Copilot Pro, MAI Code 2 is the cheapest serious coding model you can run today, and its weak spot — big repo-scale work — is the one thing you should test before switching your whole workflow to it.
What MAI Code 2 actually is
Let me clear up the name first, because Microsoft launched a whole family at once and it’s easy to mix them up. At Ignite 2026, Microsoft AI announced seven new models: MAI Cyber 2 Flash, MAI Code 2, MAI Code 2 Flash, MAI Image 2.7, MAI Realtime 1, Dragon Copilot Transcribe, and Decision 1.1. The two that matter for developers are MAI Code 2 and its lighter sibling, MAI Code 2 Flash.
MAI Code 2 is the flagship. Microsoft built it from scratch for everyday enterprise coding — taking code to production, deep debugging, multi-file implementation, repo-wide reasoning, and front-end work. Under the hood it’s a sparse Mixture-of-Experts transformer with about 2.8 trillion total parameters and 77 billion active, trained on roughly 50 trillion tokens with a knowledge cutoff of August 2026. It also has a vision encoder baked in, so it can look at screenshots and UI mockups, not just text.
The context window is 1,050,000 tokens, with up to 922,000 tokens of input and 128,000 tokens of output in a single call. That’s the same ballpark as the big frontier models, and it matters more than it sounds — a million-token window means you can hand it a whole codebase, not just one file, and ask it to reason across it.
You can also dial its reasoning effort up and down: low, medium, high, xhigh, and max. Low is fast and cheap for routine edits; max is the setting Microsoft used for all its benchmark runs, and it’s the one that costs the most. Most people will live somewhere in the middle, and that’s worth keeping in mind when you see the benchmark scores later — those were all run at max effort.
One more thing Microsoft says plainly in the model card: MAI Code 2 is “explicitly not yet tuned for harder problems, like fundamental science research and very long-horizon agentic work.” That’s not marketing modesty. It’s a real limit, and it shows up in the benchmarks — I’ll get to that.
The pricing — and the promo catch
Here’s the price table, straight from GitHub’s Copilot pricing docs. Microsoft’s own announcement post doesn’t publish per-token prices at all — only the relative percentage claims — so GitHub’s docs are the source for these numbers.
| Model | Input / 1M tokens | Cached input / 1M | Output / 1M tokens | Until |
|---|---|---|---|---|
| MAI Code 2 (promo) | $0.50 | $0.025 | $2.50 | May 17, 2027 |
| MAI Code 2 (list) | $1.00 | $0.05 | $5.00 | From May 17, 2027 |
| MAI Code 2 Flash (promo) | $0.05 | $0.005 | $0.25 | May 17, 2027 |
| MAI Code 2 Flash (list) | $0.10 | $0.01 | $0.50 | From May 17, 2027 |
Read that again: every rate doubles on May 17, 2027. The 50% launch promo runs for six months from launch, then it’s gone. So when Microsoft says MAI Code 2 costs 5% of Claude Opus 5.5, that’s the promo price talking. At list price, the honest number is closer to 10% of Opus 5.5’s cost per task — still a 10x saving, still remarkable, but not 5%. Against GPT-6.1 Sol, the “40% of the cost” claim becomes roughly 80% at full price. And Flash, the cheap sibling, actually becomes more expensive than GPT-6 Luna per task once the promo ends. I’ll spell out the math in the comparison section below.
How you pay is different from the OpenAI or Anthropic APIs, too. MAI Code 2 is billed through GitHub Copilot’s usage-based billing, in AI credits, where one AI credit equals $0.01. So a million input tokens at the promo rate costs 50 credits, and a million output tokens costs 250. Your Copilot plan includes a monthly credit allowance — Pro gets 1,500 credits a month, Pro+ gets 7,000, Max gets 20,000 — and usage beyond that is billed on top. Heavy use can burn through credits faster than you’d expect, so the per-token price is only half the story; your plan’s allowance is the other half.
There’s no batch discount, either. OpenAI and Anthropic both offer 50% off for batch API calls. Microsoft has published nothing of the sort for MAI Code 2, so don’t plan your costs around one. And there’s no separate cache-write price published — cache reads are $0.025 per million tokens at the promo rate, which is genuinely cheap, but cache writes aren’t broken out the way Anthropic breaks them out.
What it actually costs to get work done
Per-token prices are abstract. What matters is what a real task costs, and Microsoft published that too — cost per task on its internal benchmark suite, measured at the promo price. MAI Code 2 came in at $0.309 per task. GPT-6.1 Sol was $0.761. Claude Opus 5.5 was $6.306.
Let that sink in. Twenty tasks on Opus 5.5 costs about $126. Twenty tasks on MAI Code 2 costs about $6. That’s the gap that makes this launch matter, and it’s not just the per-token price — MAI Code 2 also uses fewer tokens per task in Microsoft’s runs, which is why the per-task ratio (about 5%) is even better than the per-token ratio (12.5% on input, since $0.50 is one-eighth of $4).
But run the same math at list price and the picture shifts. The same token trace would cost about $0.618 per task — still roughly 10% of Opus 5.5, but about 81% of GPT-6.1 Sol’s cost. So the honest headline is: MAI Code 2 is dramatically cheaper than Claude, and cheaper than GPT-6.1 Sol until May 2027, after which the gap with OpenAI mostly closes. If you’re budgeting for a team, budget at the list price. The promo is a gift, not a plan.
The other cost question is access. MAI Code 2 needs a paid Copilot plan — Pro at $10 a month and up — on an annual plan. It’s not on Copilot Free or Student. Flash is the one free users get, and only through automatic model selection, not by picking it directly. So the “$0.50 per million tokens” headline has a $10-a-month floor under it, plus whatever credits you burn. For a solo developer that’s still cheap. For a team running it all day, the credit meter is the thing to watch.
GitHub Copilot: where it lives and how to use it
At launch, GitHub Copilot is the only place MAI Code 2 exists. It’s not in Azure AI Foundry as a purchasable API — that trips a lot of people up, because Microsoft’s launch coverage talks about Foundry a lot. The truth is narrower: only Flash is in Foundry, and only as a limited-access preview. Code 2 itself is Copilot-only for now, with OpenRouter, Vercel, Hermes, OpenCode, and Kilo listed as “coming soon” with no date attached.
Inside Copilot, it’s everywhere you’d expect. You pick it from the model picker in VS Code, Visual Studio, the Copilot CLI, the Copilot cloud agent, the Copilot app, github.com, GitHub Mobile, JetBrains, Xcode, and Eclipse. It has also joined Copilot Fusion Standard, which is GitHub’s automatic model selection — the system picks the best model for the task instead of you choosing. Business and Enterprise admins control access through the model policy in Copilot settings, and under default enablement new models switch on automatically unless an admin turned that off.
Which plans get it? MAI Code 2 is on Copilot Pro, Pro+, Max, Business, and Enterprise. Flash is on all plans including Free and Student. The plan prices, for context: Pro is $10 a month with 1,500 AI credits, Pro+ is $39 a month with 7,000 credits, Max is $100 a month with 20,000 credits, and Free is $0 with limited usage and auto model selection only.
One practical heads-up if you’re already using Microsoft’s older coding models: MAI-Code-1.1-Flash retires across all GitHub Copilot experiences on December 18, 2026. The original MAI-Code-1-Flash was already retired on September 10, 2026. If you have pinned model strings, CLI scripts, Actions workflows, or custom agents naming MAI-Code-1.1-Flash, they’ll break on December 18 — update them before then. GitHub suggests the latest MAI Code Flash model as the replacement.
The Claude comparison — the part Microsoft wants you to see, and the part it doesn’t
Microsoft’s headline claim is that MAI Code 2 delivers 96% of Claude Opus 5.5’s performance at 5% of the cost, and 98% of GPT-6.1 Sol at 40% of the cost. Both numbers are real — on Microsoft’s own benchmark average, at the promo price. But the comparison has two wrinkles worth knowing about before you repeat the headline.
First, the price math. Here’s the full comparison table, with every price verified live on November 21, 2026:
| Model | Input / 1M | Cached input / 1M | Output / 1M | Context |
|---|---|---|---|---|
| MAI Code 2 (promo) | $0.50 | $0.025 | $2.50 | 1.05M |
| MAI Code 2 (list) | $1.00 | $0.05 | $5.00 | 1.05M |
| MAI Code 2 Flash (promo) | $0.05 | $0.005 | $0.25 | 1.05M |
| GPT-6.1 Sol | $2.00 | $0.10 | $10.00 | 1.05M |
| Claude Opus 5.5 | $4.00 | $0.20 | $20.00 | 1M |
| Claude Fable 5.2 | $8.00 | $0.20 | $40.00 | 1M |
| Claude Haiku 5.5 | $0.10 | $0.01 | $0.50 | 1M |
| GPT-6 Luna | $0.10 | $0.01 | $0.50 | 1.05M |
Opus 5.5 costs $4 in and $20 out. MAI Code 2 at promo costs $0.50 in and $2.50 out — exactly one-eighth the per-token price. That’s 12.5%, not 5%. The “5%” headline is a per-task figure: MAI Code 2 used fewer tokens per task in Microsoft’s benchmark runs, and the promo price stacked on top of that. Both are legitimate measurements, but they’re different measurements, and mixing them up is how people end up with wrong budgets. If you want the full story on Fable 5.2 — Anthropic’s top reasoning model at $8/$40, twice Opus’s price — I covered it in detail in my Claude Fable 5.2 pricing breakdown.
Second, the category stretch. Microsoft compares MAI Code 2 against Opus 5.5, which is Anthropic’s coding flagship — fair enough. But it doesn’t compare against Fable 5.2, Anthropic’s top reasoning model, which costs twice as much as Opus and scores higher on the independent Artificial Analysis index (65 vs Opus’s lower tier). Beating Opus on price is not the same as beating Fable. If your work is the hardest reasoning-heavy coding, Fable 5.2 is still the model to beat, and MAI Code 2 hasn’t been measured against it. I compared the two Anthropic flagships head-to-head with OpenAI’s newest model in my GPT-6.2 Astra vs Claude Fable 5.2 article — worth a read if you’re choosing between the top tier.
There’s also a tokenizer wrinkle that makes Claude look cheaper than it is. Anthropic’s own docs note that Claude 4.7+ models use a newer tokenizer that produces roughly 30% more tokens for the same text. So the headline per-token rates understate the effective cost of Claude versus GPT or MAI models. It doesn’t flip the comparison — MAI Code 2 is still far cheaper — but it means the gap is a bit wider than the table suggests, in MAI’s favor.
And one freshness note: GPT-6.2 Sol launched on November 17, 2026 — the same day as MAI Code 2 — at the same $2/$10 rates as GPT-6.1 Sol. If you see “GPT-6.1 Sol” in Microsoft’s comparison, that’s the model they benchmarked, but 6.2 is the current one. The price is the same, so the math holds either way.
The benchmarks — and the weak spot Microsoft hopes you skip
Every MAI Code 2 score below is Microsoft’s own, run on its internal MSBench platform through the GitHub Copilot CLI, all models at max reasoning effort, no subagents. No independent benchmark of MAI Code 2 existed as of November 21, 2026 — it’s not on the Artificial Analysis index yet. That doesn’t make the numbers fake, but it does make them one-sided, and you should read them that way.
| Benchmark | MAI Code 2 | GPT-6.1 Sol | Claude Opus 5.5 |
|---|---|---|---|
| DeepSWE 1.1 | 73.2% | 74.6% | 69.0% |
| Terminal-Bench 2.1 | 84.6% | 85.0% | 78.7% |
| SWE-Atlas | 43.1% | 47.4% | 57.5% |
| FrontierCode v1.1 | 52.0% | 49.4% | 56.0% |
| Average pass rate | 63.2% | 64.1% | 65.3% |
| Cost per task (promo) | $0.309 | $0.761 | $6.306 |
The averages are where the headlines come from: 63.2 divided by 64.1 is 98% of GPT-6.1 Sol; 63.2 divided by 65.3 is 96% of Opus 5.5. And MAI Code 2 genuinely beats Opus on DeepSWE and Terminal-Bench — those are real wins in software engineering and terminal-based agentic tasks.
But look at the SWE-Atlas row. That’s the benchmark for codebase Q&A, test writing, and refactoring across 18 open-source projects — the closest thing in this set to real day-to-day work in a big repo. MAI Code 2 scores 43.1%. Opus 5.5 scores 57.5%. That’s a 14.4-point gap, and it’s the biggest loss on the table. It lines up exactly with Microsoft’s own caveat that the model isn’t tuned for very long-horizon agentic work yet. If your job is small-to-medium tasks — a feature here, a bug fix there, a component rebuild — MAI Code 2 looks great. If your job is “understand this 200,000-line codebase and refactor the auth layer across 40 files,” Opus is still the safer pick, and it’s not close.
There’s one more benchmark worth mentioning because it’s the kind of thing that actually affects your daily work. In blind tests of frontend apps — UIs, games, data visualizations, SVG graphics — developers preferred MAI Code 2’s output over GPT-6 Sol 64% of the time. That’s Microsoft-reported too, so take it with the same pinch of salt, but if front-end work is a big part of your day, it’s a encouraging sign. The model card’s vision encoder is presumably doing real work here.
MAI Code 2 Flash — the cheap sibling that might be the real story
Don’t sleep on Flash. MAI Code 2 Flash is the lighter model — about 398 billion total parameters with 12 billion active — built for high-volume routine work: code explanations, targeted edits, routine fixes, rapid iteration. It’s the one on every Copilot plan, including Free and Student, and its promo price is almost silly: $0.05 per million input tokens and $0.25 per million output tokens.
On Microsoft’s three-benchmark average, Flash scores 61.0% — ahead of GPT-6 Luna at 55.1% and Claude Haiku 5.5 at 53.9%. Its cost per task is $0.052 at promo price, against $0.080 for Luna and $0.319 for Haiku 5.5. Microsoft’s claim is that Flash gives comparable performance to Luna at 65% of the cost and to Haiku 5.5 at 20% of the cost.
Same promo warning applies, though — and for Flash it’s sharper. At list price, Flash costs about $0.104 per task, which is roughly 130% of Luna’s cost. In other words, after May 17, 2027, Flash stops being the cheap option against OpenAI’s small model and becomes the pricier one. If you’re building a workflow around Flash’s price, build it around the list price, or at least set a calendar reminder for May.
For most developers, my honest take is that Flash is the model you’ll actually use most. The full Code 2 is the flagship, but Flash handles the routine 80% of coding work — explanations, small edits, quick fixes — at a tenth of Code 2’s price, and it’s available to everyone, including free users. Try Flash first. Reach for Code 2 when the task is genuinely hard.
The gotchas nobody puts in the launch post
Every launch has fine print. Here’s the fine print I found, all from Microsoft’s own docs or reputable reports.
The promo cliff is the big one. Prices double on May 17, 2027. Any cost comparison that uses $0.50/$2.50 without the date is misleading, and I’ve now said it three times in this article because it matters that much. If a blog post or YouTube video quotes the promo price without the expiry date, it’s out of date the moment you read it — or it will be in six months.
The weights are closed. The model card states plainly that weights are “not distributed, hosted on Azure.” There’s no open-weight download, no public license, no self-hosting. Microsoft did announce something called MAI Licensed Weights at the same Ignite launch — selected enterprises can license MAI model weights, customize them with their own data, and run them inside their own Azure environment — but that’s enterprise-only, built through Microsoft’s Frontier Company engagements, with no published prices or terms. Microsoft’s Mustafa Suleyman said it would “feel like open source.” It isn’t open source. Don’t let anyone tell you otherwise.
There’s no public API outside Copilot. Code 2 isn’t something you can call from your own app today. OpenRouter, Vercel, Hermes, OpenCode, and Kilo are “coming soon” with no date. If your workflow needs API access rather than an editor integration, you’re waiting — or you’re using GPT or Claude through their APIs, which is exactly the competition Microsoft is trying to undercut.
No batch discount, no EU data-residency promise. Microsoft has published no batch pricing for MAI Code 2, and there’s no documented EU data-zone commitment for it. If either of those is a hard requirement for your team, verify it directly with Microsoft before committing — don’t take a blog post’s word for it, including mine.
The rivalry behind the launch is messy. The Information reported on launch day that Microsoft is working to replace Anthropic models in Copilot with OpenAI models, which are cheaper for Microsoft — and MAI Code 2 is the in-house lever in that shift. That’s a report, not a confirmed fact, and Microsoft hasn’t confirmed it. The backdrop is genuinely complicated: Microsoft invested $5 billion in Anthropic while Anthropic committed $30 billion to Azure. The companies are partners, rivals, and customers of each other all at once. What it means for you is simpler: Microsoft has a strong incentive to make MAI Code 2 good, because every Copilot user it moves off Anthropic saves Microsoft money. That incentive cuts in your favor.
Safety is taken seriously, at least on paper. The model card describes safety training across the pipeline — pre-training filtering, safety data covering refusal of CBRN, child safety, self-harm, and violent or hateful content, plus jailbreak and indirect-prompt-injection resistance and agentic safety against destructive or unauthorized tool actions. Deployment adds platform-level safety classifiers, including frontier cybersecurity and biosecurity classifiers. Separately, Microsoft published an MAI Code of Conduct in September 2026 barring its models from resisting shutdown, hiding reasoning, or expanding their own scope. Good to know, hard to verify from outside — but the direction is right.
My verdict: who should switch, and who shouldn’t
I’ve spent the last few days with this launch, and here’s where I land.
Switch to MAI Code 2 if: you already pay for Copilot Pro or above; your work is mostly feature implementation, debugging, and front-end tasks; you run a lot of coding tasks and the per-task cost actually matters to you; or you’re a student or free-tier user who wants to try Flash, which costs almost nothing and beats Luna and Haiku on Microsoft’s benchmarks. For this group, MAI Code 2 is the best value in AI coding right now, and it’s not particularly close — a tenth of Opus’s cost per task at list price is a genuine shift, not a rounding error.
Stay with Claude if: your work is large-scale repo refactoring, long-horizon agentic runs, or the kind of deep codebase reasoning where SWE-Atlas says Opus wins by 14 points. If you’re the person who hands a model a 200,000-line codebase and says “refactor the auth layer,” Opus 5.5 is still your model, and the price difference is the cost of getting it right the first time. Fable 5.2 is the pick if you want Anthropic’s absolute best reasoning and you’re willing to pay $8/$40 for it.
Stay with OpenAI if: you need API access outside an editor, or batch pricing, or you just want the broadest ecosystem. GPT-6.2 Sol launched the same day at the same $2/$10 rates, and OpenAI’s API is the one everything integrates with. MAI Code 2 being Copilot-only is a real limitation for anyone building products on top of a model.
For most people reading this, the practical move is simple: you’re already paying for Copilot, so try MAI Code 2 on your next real task — not a toy example, a real one — and compare it against what you were using. Set the reasoning effort to high for anything that matters. Watch your credit usage for a week. And remember the date: May 17, 2027. That’s when the price doubles, and that’s when you re-run this comparison for real.
The bigger picture is what excites me most. A year ago, the idea that Microsoft — the company that spent billions partnering with OpenAI and Anthropic — would ship its own coding model that beats them on price by an order of magnitude felt far-fetched. Now it’s here, it’s in the editor millions of developers already use, and the competition it creates pushes every other vendor to get cheaper and better. Whatever model you end up using, that’s good news for you.
Frequently asked questions
How much does MAI Code 2 cost?
$0.50 per million input tokens and $2.50 per million output tokens until May 17, 2027, then $1.00 and $5.00. Cache reads are $0.025 per million tokens at the promo rate. You pay through GitHub Copilot’s usage-based billing in AI credits, and you need a paid Copilot plan (Pro $10/month and up) to use it.
Is MAI Code 2 available in Azure AI Foundry?
Not as a purchasable API. Code 2 is GitHub Copilot-only at launch. Only the lighter Flash model is in Foundry, as a limited-access preview. OpenRouter, Vercel, Hermes, OpenCode, and Kilo are listed as coming soon with no date.
Is MAI Code 2 better than Claude Opus 5.5?
On Microsoft’s own benchmarks, it scores 96% of Opus 5.5’s average performance at about 5% of the cost per task (promo price). It beats Opus on DeepSWE and Terminal-Bench, but loses badly on SWE-Atlas (43.1% vs 57.5%), which measures repo-scale work. For everyday coding tasks it’s a strong, much cheaper alternative; for big refactors, Opus is still ahead.
Is MAI Code 2 free?
No. There’s no free tier for Code 2 — it’s not on Copilot Free or Student. The lighter Flash model is available on all plans including Free, through automatic model selection. Flash costs $0.05/$0.25 per million tokens at the promo rate.
Is MAI Code 2 open source?
No. The weights are closed and hosted on Azure. Microsoft’s MAI Licensed Weights program lets selected enterprises license and customize weights inside their own Azure environment, but that’s enterprise-only, not open source, and there’s no self-service access.
When does the MAI Code 2 promo price end?
May 17, 2027. On that date every rate doubles: Code 2 goes from $0.50/$2.50 to $1.00/$5.00 per million tokens, and Flash goes from $0.05/$0.25 to $0.10/$0.50.
Sources
- Microsoft AI announcement: Introducing MAI Code 2 and MAI Code 2 Flash
- MAI Code 2 and MAI Code 2 Flash model card (PDF, November 17, 2026): Model Card
- GitHub Changelog: MAI Code 2 and MAI Code 2 Flash in GitHub Copilot
- GitHub Changelog: Upcoming deprecation of MAI Code 1.1 Flash in December
- Anthropic official pricing: Claude API pricing
- InfoWorld: Microsoft launches MAI Code 2 models to challenge OpenAI and Anthropic in AI coding
Prices checked November 21, 2026. The 50% launch promo ends May 17, 2027 — re-check prices before making a buying decision, because the promo rate will not be the rate you pay after that date.


