Skip to main content
  • Pricing
Comparisons

GLM-5 explained: specs, 200K context, API price and license as Z.ai documents them

By Oakgen TeamPublished 3 min read

Share
GLM-5 explained: specs, 200K context, API price and license as Z.ai documents them

GLM-5 is a text-only foundation model from Z.ai (Zhipu AI), released in February 2026 for coding and long-running agent tasks. According to Z.ai it is a mixture-of-experts model with 744B total and 40B active parameters, a 200K context window and API pricing of $1 per 1M input tokens and $3.2 per 1M output tokens as of 2026-11-19. Z.ai has since released GLM-5.1, 5.2 and 5.3, so GLM-5 is now the oldest release in the GLM-5 series.

What Z.ai says GLM-5 is

Z.ai's developer documentation calls GLM-5 a foundation model designed for "Agentic Engineering": complex system engineering and long-range agent tasks rather than short code snippets. The release note dated 2026-02-12 says it targets backend architecture, complex algorithms and difficult bug fixing, and that it benchmarks directly against Claude Opus 4.5 on code-logic density and systems engineering.

The Hugging Face model card gives the lineage. Compared with GLM-4.5, GLM-5 grows from 355B parameters (32B active) to 744B (40B active), and pre-training data rises from 23T to 28.5T tokens. It also integrates DeepSeek Sparse Attention (DSA), which the card says largely reduces deployment cost while preserving long-context capacity. For post-training, Z.ai built an asynchronous reinforcement learning system called slime. The technical report on arXiv (2602.15763, "GLM-5: from Vibe Coding to Agentic Engineering") describes the same two ideas: DSA to cut training and inference cost, and asynchronous RL that decouples generation from training.

Specs at a glance

ItemValueWhere it comes from
Input and outputText onlyZ.ai API docs
Context length200KZ.ai API docs
Maximum output128KZ.ai API docs
Parameters744B total, 40B activeZ.ai docs and model card
Pre-training data28.5T tokensZ.ai docs and model card
Layers and experts78 layers, 256 routed experts, 8 experts per tokenconfig.json in the Hugging Face repo
Position limit202752config.json (max_position_embeddings)
API model IDglm-5Z.ai API docs

The documentation lists thinking mode, streaming, function calling, context caching and structured output (such as JSON) as supported capabilities. One small discrepancy is worth knowing: the model card text says 744B parameters, while Hugging Face's own file counter on the same page shows 754B. Treat 744B as the publisher's figure.

Performance claims, and how to read them

The model card publishes a benchmark table that compares GLM-5 with GLM-4.7, DeepSeek-V3.2, Kimi K2.5, Claude Opus 4.5, Gemini 3 Pro and GPT-5.2. A few GLM-5 numbers from it: 77.8 on SWE-bench Verified, 56.2 on Terminal-Bench 2.0 (the card also lists 60.7 on a corrected version of that benchmark), 86.0 on GPQA-Diamond, 62.0 on BrowseComp and 89.7 on tau-squared-Bench. In the same table Claude Opus 4.5 scores 80.9 and GPT-5.2 scores 80.0 on SWE-bench Verified, so Z.ai's own table shows GLM-5 behind those two on that test while ahead of Gemini 3 Pro at 76.2.

These are vendor-run results. The card's footnotes list the settings used, including temperature, output limits and the agent harness, and note that one score (Vending Bench 2) was run independently by Andon Labs. Different harnesses and settings change scores, so use the table to see where Z.ai claims strengths, then run your own tasks.

Price and a worked example

Z.ai's pricing page lists these API rates per 1M tokens as of 2026-11-19. The page has no date of its own.

ModelInputCached inputOutput
GLM-5$1$0.2$3.2
GLM-5.1$1.4$0.26$4.4
GLM-5.2$1.4$0.26$4.4
GLM-5.3$1.4$0.26$4.4
GLM-5.3-Flash$0.15$0.03$0.50

Cached-input storage is marked "Limited-time Free" for these models. As a worked example at list price with no caching, a job that sends 10M input tokens and receives 2M output tokens costs 10 x $1 + 2 x $3.2 = $16.40 on GLM-5, against 10 x $1.4 + 2 x $4.4 = $22.80 on GLM-5.3. Hosted resellers may charge different rates, so this applies only to Z.ai's own API.

Where to get it, and the license

There are three routes. The API uses the model ID glm-5 at Z.ai's chat completions endpoint. The weights are on Hugging Face and ModelScope in BF16 and FP8 builds. Z.ai's chat site is also linked from the model card. On local serving, the card lists vLLM (v0.19.0 or later), SGLang (v0.5.10 or later), KTransformers, Transformers and xLLM, and its example vLLM command uses tensor parallelism across 8 GPUs. A 744B-parameter model is a multi-GPU deployment, not a laptop model.

On licensing, the Hugging Face card metadata says MIT. The LICENSE file in the zai-org/GLM-5 GitHub repository is the Apache License 2.0, and the repository's README does not discuss licensing. The two statements are not identical, so read the license that accompanies the files you actually use.

How GLM-5 relates to the later models

Z.ai's release notes list the family in this order.

ModelRelease note dateWhat the notes say
GLM-52026-02-12Agentic engineering, DSA, 744B (40B active)
GLM-5.12026-04-07Long-horizon work, up to 8 hours in a single run
GLM-5.22026-06-161M context, stronger coding and long-horizon results
GLM-5.32026-08-18Coding gains over 5.2, cybersecurity results
GLM-5.3-Flash2026-08-26320B total, 18B active, hybrid sparse and linear attention

The GitHub README adds that GLM-5.3 uses the same base model as GLM-5.2, with gains coming from post-training, while GLM-5.3-Flash starts from a newly trained base. The README is now titled for the whole GLM-5 series rather than GLM-5 alone.

Take this further with Oakgen Agent

Run the cost calculations, draft a short evaluation brief and export it as a document or spreadsheet; it can search the web for current vendor docs.

Looking for a recap of one specific YouTube video? The YouTube Summarizer does that today.

Open this task in Oakgen Agent

The prompt is filled in for you. Nothing is sent until you press send.

Open in Oakgen Agent

Frequently asked questions

When was GLM-5 released?

Z.ai's release notes list GLM-5 under 2026-02-12. The Hugging Face repository zai-org/GLM-5 was created on 2026-02-11 according to Hugging Face's model metadata, and the technical report (arXiv 2602.15763) was submitted on 17 February 2026 and revised on 24 February 2026. As of 2026-11-19 Z.ai's release notes also list GLM-5.1 (2026-04-07), GLM-5.2 (2026-06-16), GLM-5.3 (2026-08-18) and GLM-5.3-Flash (2026-08-26).

How big is GLM-5 and what context window does it have?

Z.ai describes GLM-5 as a model with 744B total parameters and 40B active per token, trained on 28.5T tokens. Its API documentation lists a 200K context length and a 128K maximum output, with text input and text output only. The configuration file in the Hugging Face repository sets max_position_embeddings to 202752, consistent with the 200K figure. Z.ai's pages describe a 1M-token context for the later GLM-5.2, not for GLM-5.

What does the GLM-5 API cost?

As of 2026-11-19, Z.ai's pricing page lists GLM-5 at $1 per 1M input tokens, $0.2 per 1M cached input tokens and $3.2 per 1M output tokens, with cached-input storage marked as limited-time free. GLM-5.1, 5.2 and 5.3 are listed at $1.4, $0.26 and $4.4 on the same basis. The page carries no date, so check it before budgeting.

Is GLM-5 open source, and under which license?

The weights are published on Hugging Face and ModelScope. The Hugging Face model card declares license: mit in its metadata. The LICENSE file at the root of Z.ai's GitHub repository zai-org/GLM-5 is the Apache License 2.0, and the GitHub README does not discuss licensing. Read the license that ships with the exact artefact you download and confirm the terms with your own counsel before commercial use.

Is GLM-5 or one of the newer GLM-5.x models the better choice?

Z.ai's pages position the later releases as improvements for long-horizon and coding work, and the API still lists GLM-5 at a lower price than 5.1 to 5.3. The pages do not say GLM-5 is retired. Whether the cheaper price outweighs the newer models' gains depends on your own workload, so test both on your tasks rather than relying on vendor benchmark tables.

Sources

  1. Z.ai Developer Docs, GLM-5 model overview (read 2026-11-19)
  2. Hugging Face, zai-org/GLM-5 model card, published by Z.ai (read 2026-11-19)
  3. Hugging Face, zai-org/GLM-5 config.json, published by Z.ai (read 2026-11-19)
  4. Z.ai Developer Docs, Pricing, undated page (read 2026-11-19)
  5. Z.ai Developer Docs, New Released (release notes), page last modified 2026-10-10 (read 2026-11-19)
  6. GitHub, zai-org/GLM-5 repository README and LICENSE (read 2026-11-19)
  7. arXiv 2602.15763, GLM-5: from Vibe Coding to Agentic Engineering, GLM-5-Team, submitted 2026-02-17 (read 2026-11-19)
Share