OpenAI Releases GPT-4.1 API With One Million Token Context
OpenAI has released GPT-4.1 via API, offering developers a one-million-token context window at reduced cost.
What Happened
OpenAI released GPT-4.1 through its developer API, introducing a one-million-token context window and pricing reductions compared to its predecessor, GPT-4o. The model is available exclusively via API and is not currently accessible through the ChatGPT consumer interface.
Key Specifications
GPT-4.1 supports a context window of one million tokens, placing it among the largest context windows available from any major commercial model provider. OpenAI also released two smaller variants alongside the flagship model: GPT-4.1 mini and GPT-4.1 nano. The nano variant is positioned as the company's lowest-cost and lowest-latency option in the GPT-4 family.
OpenAI stated that GPT-4.1 shows meaningful improvements over GPT-4o on coding and instruction-following benchmarks. The company reported the model scores higher on the SWE-bench coding evaluation, which tests a model's ability to resolve real-world software engineering tasks drawn from GitHub repositories.
Pricing
OpenAI priced GPT-4.1 at two dollars per million input tokens and eight dollars per million output tokens. GPT-4.1 mini is priced at forty cents per million input tokens and one dollar and sixty cents per million output tokens. GPT-4.1 nano is priced at ten cents per million input tokens and forty cents per million output tokens. All three models support the one-million-token context window.
The input pricing for GPT-4.1 represents a reduction compared to GPT-4o, which OpenAI currently prices at two dollars and fifty cents per million input tokens.
Background
OpenAI introduced the GPT-4 model family in March 2023. The company has since released multiple variants, including GPT-4 Turbo and GPT-4o, the latter of which added multimodal capabilities covering text, audio, and image inputs. GPT-4.1 does not replace GPT-4o in the product lineup. OpenAI stated that GPT-4o will remain available and continues to serve as the default model in ChatGPT.
The one-million-token context window matches the capacity Google introduced with Gemini 1.5 Pro in 2024 and aligns with the context window announced for GPT-4.1 prior to its broader availability. For reference, one million tokens corresponds to roughly seven hundred fifty thousand words, or approximately the combined length of the first seven Harry Potter novels.
What It Means in Practice
The extended context window allows developers to pass significantly larger volumes of text, code, or documents into a single API call without splitting inputs across multiple requests. Use cases identified by OpenAI include processing entire codebases, long legal or financial documents, and extended multi-turn conversation histories.
The addition of GPT-4.1 nano expands OpenAI's low-cost tier, an area where the company faces competition from providers including Google, Anthropic, and open-weight model distributors such as Meta. The nano model is targeted at high-volume, latency-sensitive applications where cost per token is a primary consideration.
OpenAI noted that GPT-4.1 demonstrates improved adherence to developer-specified instructions, a capability that is relevant for agentic workflows where models must follow multi-step task specifications without deviation.
What Comes Next
OpenAI has not announced a timeline for making GPT-4.1 available within the ChatGPT consumer product, and the company has said it will continue updating its model availability and deprecation schedules on its developer documentation pages.
Get our editors' take on what it all means. Read the Editor's Blog →