GPT-4.1: Pricing, Context, and Benchmarks

GPT-4.1 is OpenAI's GPT-4 model released on 2025-04-14. It runs on a 1.0M-token context window, priced at $2.00/M input and $8.00/M output. 1M-token context window. Best OpenAI choice for long-context coding and document tasks.

Input
$2.00/M
Output
$8.00/M
Cached input
$0.5000/M
Context
1.0M
Max output
33K

Specifications

ProviderOpenAI
FamilyGPT-4
Released2025-04-14
Statusactive
Context window1.0M tokens
Max output33K tokens
Modalitiestext image
Capabilities function calling json mode vision streaming
Tokenizero200k_base
API endpointhttps://api.openai.com/v1/chat/completions
DocumentationOfficial docs ↗
Last updated2026-05-29

What this model is good for

Based on benchmark scores and capability fit, GPT-4.1 ranks well for:

  • Long Context Summarization — rank #3. 1M context with stronger reasoning than Gemini on synthesis-heavy tasks.
  • Code Generation — rank #6. 1M context advantage when the whole codebase needs to fit in the prompt.

Cost calculator

For 1,000 tokens of input and 1,000 tokens of output per call, this model costs $0.0100 per call. For typical usage:

WorkloadTokens / call (in/out)$/call$/1K calls$/1M calls
Short Q&A 200 / 100 $0.001200 $1.20 $1,200
Standard chat 1K / 500 $0.006000 $6.00 $6,000
RAG with retrieval 4K / 500 $0.012000 $12.00 $12,000
Long doc summary 20K / 1K $0.048000 $48.00 $48,000
Long context (100K input) 100K / 2K $0.212000 $212.00 $212,000

For more precise estimates including caching discounts, use the LLM API Cost Calculator.

Other OpenAI models

Common comparisons

API setup

curl https://api.openai.com/v1/chat/completions \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model": "gpt-4-1", "messages": [{"role": "user", "content": "Hello"}]}'

See the official documentation for the full request/response schema. For pre-flight token counting before paying, use the appropriate token counter.