What is MAI Code 2?

MAI Code 2 is a frontier AI coding model developed by Microsoft AI to support enterprise software development, code generation, debugging, and agent-assisted programming workflows. The model is designed to perform practical engineering tasks across existing repositories, including feature implementation, code modification, application maintenance, and production-oriented development. Its decoder-only transformer architecture incorporates sparse Mixture-of-Experts layers and a vision encoder, with approximately 80 billion active parameters. MAI Code 2 supports text and image inputs, an input limit of 922,000 tokens, and a maximum output of 128,000 tokens within its approximately 1.05-million-token context window. These capabilities allow the model to analyze large codebases, interpret technical documentation, and coordinate changes across multiple files and software components. Its reasoning capabilities support deep debugging, repository-wide analysis, implementation planning, and generating code intended to satisfy existing application requirements. The model is also optimized for visual software development, including building frontend interfaces, dashboards, interactive graphics, and data visualizations from natural-language descriptions. In Microsoft's published evaluations across DeepSWE 1.1, Terminal Bench 2.1, SWE-Atlas, and FrontierCode v1.1, MAI Code 2 achieved an average of 98% of GPT-6.1 Sol's performance at 40% of its cost and 96% of Claude Opus 5.5's performance at 5% of its cost. Microsoft also reports that developers preferred MAI Code 2 over GPT-6 Sol in 64% of blind frontend evaluations involving user interfaces, games, visualizations, and other graphical applications. Available through GitHub Copilot, with additional developer platform integrations planned, MAI Code 2 helps software engineers automate complex programming activities and develop production-ready applications with improved cost efficiency.

Pricing

Price Starts At:
$0.50 per 1M tokens (input)
Price Overview:
$0.50 per 1 million input tokens and $2.50 per 1 million output tokens (with cached input reads at $0.025 per 1M tokens)

Screenshots and Video

MAI Code 2 Screenshot 1

Company Facts

Company Name:
Microsoft AI
Date Founded:
2024
Company Location:
United States
Company Website:
microsoft.ai/

Product Details

Deployment
SaaS
Training Options
Documentation Hub
Support
Web-Based Support

Product Details

Target Company Sizes
Individual
1-10
11-50
51-200
201-500
501-1000
1001-5000
5001-10000
10001+
Target Organization Types
Mid Size Business
Small Business
Enterprise
Freelance
Nonprofit
Government
Startup
Supported Languages
English

MAI Code 2 Categories and Features