Skip to content
Dashboard

Gemini 4 Carbon now available on AI Gateway

Gemini 4 Carbon from Google is now available on AI Gateway. It is available at 50% off through November 30, 2026:

Gemini 4 Carbon is built for complex software engineering, sustained agentic work, and cybersecurity defense. It has a 1M-token context window for working with large codebases and long inputs.

On engineering tasks, Carbon carries demanding work through multiple stages, with improvements in coding, full-stack web development, and scientific reasoning. Its cybersecurity capabilities span finding vulnerabilities, validating their risk, and developing patches. Google also reports more reliable execution of multi-step plans, fewer unsupported claims, and better collaboration when requirements are ambiguous, helping agents follow through while respecting project constraints.

Use google/gemini-4-carbon as the model name:

import { streamText } from 'ai';
const result = streamText({
model: 'google/gemini-4-carbon',
prompt: 'Write a TypeScript helper that safely parses JSON and returns a fallback.',
});
for await (const text of result.textStream) {
process.stdout.write(text);
}

To use it in Claude Code, Codex, Cursor, and more, install the latest Vercel CLI and run setup:

npx vercel ai-gateway setup

Then select google/gemini-4-carbon in the agent. See the coding agents guide for details.

Try Gemini 4 Carbon in the model playground.

AI Gateway provides a unified API for calling models, tracking usage and cost, and configuring retries, failover, and performance optimizations for higher-than-provider uptime. It includes built-in custom reporting, Zero Data Retention support, budgets for API keys, routing rules, and more.

AI Gateway reflects provider pricing with no markup and does not charge a platform fee on inference, including on Bring Your Own Key (BYOK) requests.

You can view all language models available on AI Gateway.