GLM 5.2: A Million-Token Window at the Same Price
Z.AI extended GLM's context window to one million tokens, shipped the weights under MIT, and didn't touch the price. A bigger model envelope for the same bill is a rare kind of upgrade.
TL;DR
- ๐ Context window extended to 1,000,000 tokens, via a small architecture change.
- ๐ต Pricing unchanged at $1.4 / $4.4 per million tokens (input / output).
- ๐ Weights released under MIT โ fully open.
- โ
Already selectable on the MegaBrain gateway as
z-ai/glm-5.2.
What shipped
GLM 5.2's headline change is a context length extended to one million tokens, which required a small architecture change. The model had quietly been available in the subscription for a few days, but the blog post, the open weights, and the API release all landed together. Pricing did not move โ it's still $1.4 / $4.4 per million tokens, and the weights are MIT-licensed.
| GLM 5.1 | GLM 5.2 | |
|---|---|---|
| Context window | 256K | 1M tokens |
| Input price | $1.4 / 1M | $1.4 / 1M (unchanged) |
| Output price | $4.4 / 1M | $4.4 / 1M (unchanged) |
| Weights | Open | MIT |
| On MegaBrain | z-ai/glm-5.1 | z-ai/glm-5.2 |
GLM 5.1 figures shown for comparison; the 5.2 numbers are from the release. Run your own evals before trusting any vendor benchmark.
Why a 1M window at flat pricing matters
A million-token window means you can load an entire monorepo, a full contract set, or weeks of an agent's history in a single call โ and because the price didn't increase, that headroom is effectively free. Open MIT weights mean you can also self-host if you need to. For an always-on agent, more context at the same rate is a direct upgrade to how much it can reason over at once.
Run it on MegaBrain
GLM 5.2 is already in the MegaBrain catalog โ no waiting, no markup:
import openai
client = openai.OpenAI(
base_url="https://getmegabrain.com/api/gateway/v1",
api_key="mb-your-key-here",
)
response = client.chat.completions.create(
model="z-ai/glm-5.2",
messages=[{"role": "user", "content": "Read this whole repo and find the dead code"}],
)See live pricing and every available model on the models page.
Source & further reading
Release spotted via @ai_newz. For the coding head-to-head, see Kimi K2.7 Code vs GLM-5.2 โ
MegaBrain Gateway
500+ models. One API. No markup.
Use in Claude Code, Cline, Cursor, or any coding agent.
Newsletter
Stay in the loop
Get the latest model comparisons and guides โ no spam, unsubscribe anytime.