# GPT-4o mini

OpenAI's cost-efficient multimodal small model: 82.0% on MMLU, higher than GPT-4 on the LMSYS chat preference leaderboard, and priced below GPT-3.5 Turbo.

- **Model ID:** `openai/gpt-4o-mini`
- **Type:** chat
- **Providers:** azure, openai
- **Context window:** 128,000
- **Maximum output tokens:** 16,384
- **Pricing:** $0.15/1M input tokens, $0.6/1M output tokens
- **Canonical page:** https://vercel.com/ai-gateway/models/gpt-4o-mini

## Supported parameters

Detailed capability metadata has not been reported for this model.

## Example

```ts
import { streamText } from 'ai'

const result = streamText({
  model: 'openai/gpt-4o-mini',
  prompt: 'Why is the sky blue?'
})
```

## About

GPT-4o mini launched on July 18, 2024 as OpenAI's cost-efficient model, positioned to replace GPT-3.5 Turbo for cost-sensitive deployments while providing meaningfully higher capability. The pricing stands out: $0.15 per million input tokens and $0.6 per million output tokens, at reduced cost compared to GPT-3.5 Turbo. It scored 82.0% on MMLU (Massive Multitask Language Understanding), exceeding GPT-3.5 Turbo, and topped GPT-4 on the LMSYS Chatbot Arena chat preference leaderboard at release.

GPT-4o mini supports vision alongside text, inheriting GPT-4o's multimodal design at the small-model tier. You can run cost-efficient image analysis, document processing, visual classification, and screenshot interpretation without routing to a larger model. Function calling support makes it viable as the reasoning layer in tool-using agents and API-calling pipelines.

OpenAI highlighted four patterns where GPT-4o mini excels: chaining or parallelizing multiple model calls, passing large volumes of context such as full codebases or conversation histories, fast real-time text responses for customer-facing interfaces, and workloads previously blocked by GPT-3.5 Turbo's capability ceiling. The context window of 128K tokens gives it substantial headroom for each of these.

## What to consider

For applications that chain multiple model calls (classify, then extract, then format), GPT-4o mini's per-call cost makes it practical to run several sequential inferences per user request without the economics becoming prohibitive.

## When to use

### Best For

- Customer support chatbots and live interaction features requiring fast, affordable multi-turn responses
- Pipelines that fire multiple sequential or parallel model calls per user action, where per-call cost accumulates quickly
- Vision-enabled workflows on a budget: image description, document OCR assistance, and visual classification
- Function-calling agents that need reliable tool invocation at low cost per call
- Processing large conversation histories or codebases within the context window of 128K tokens at minimal cost

### Consider Alternatives When

- Output quality on complex reasoning, nuanced writing, or difficult coding tasks falls short; GPT-4o or GPT-4.1 provide a higher ceiling
- More capable vision or audio processing is required
- Deep chain-of-thought reasoning is the primary need; o1-mini is purpose-built for that

## Best for

- **Customer support chatbots:** Live interaction features requiring fast, affordable multi-turn responses
- **Multi-call pipelines:** Sequential or parallel model calls per user action where per-call cost accumulates quickly
- **Budget vision workflows:** Image description, document OCR assistance, and visual classification at the small-model tier
- **Function-calling agents:** Reliable tool invocation at low cost per call
- **Large conversation histories:** Processing codebases and extended chats within the context window of 128K tokens at minimal cost

## Consider alternatives

- **Higher quality ceiling:** GPT-4o or GPT-4.1 handle complex reasoning, nuanced writing, or difficult coding tasks better
- **Advanced multimodal processing:** More capable vision or audio workloads require a larger model
- **Deep chain-of-thought:** o1-mini is purpose-built for extended reasoning

## Frequently asked questions

### How does GPT-4o mini compare to GPT-3.5 Turbo on price?

Pricing appears on this page and updates as providers adjust their rates. AI Gateway routes traffic through the configured provider.

### Does GPT-4o mini support image input?

Yes. It supports vision alongside text, enabling image analysis, document processing, and visual classification at the small-model cost tier.

### What benchmark scores did GPT-4o mini achieve?

82.0% on MMLU, outperforming comparable small models and topping GPT-4 on the LMSYS Chatbot Arena chat preference leaderboard at launch.

### Is GPT-4o mini suitable for function calling and tool use?

Yes. Function calling is supported, and OpenAI highlighted agentic pipelines that call external APIs as one of the key intended use cases.

### What is the context window for GPT-4o mini?

128K tokens, providing ample space for conversation histories, long codebases, and extended document processing.

### How does gpt-4o-mini (the alias) differ from gpt-4o-mini-2024-07-18?

The alias `gpt-4o-mini` points to the current recommended version and may be updated. The dated snapshot `gpt-4o-mini-2024-07-18` is pinned to the specific July 18, 2024 release.

### What are typical latency characteristics?

This page shows live throughput and time-to-first-token metrics measured across real AI Gateway traffic.

## Links

- [Model page](https://vercel.com/ai-gateway/models/gpt-4o-mini)
- [AI Gateway documentation](https://vercel.com/docs/ai-gateway)
- [Provider model documentation](https://learn.microsoft.com/en-us/azure/ai-foundry/foundry-models/concepts/models-sold-directly-by-azure?pivots=azure-openai&tabs=global-standard-aoai%2Cstandard-chat-completions%2Cglobal-standard#gpt-5.1)
- [Provider pricing](https://platform.openai.com/docs/pricing)
