GLM-5
z-ai/glm-5
Back to model catalog

Z.ai · Model guide

GLM-5

Compare
z-ai/glm-5

The first GLM-5 foundation model, an open 744B sparse MoE with 40B active parameters, built for complex system engineering and long-range agents. It emphasizes backend refactoring, deep debugging, tool orchestration and sustained execution over isolated code generation.

Modalities
TextText
Context
200K
Max output
128K
Price / 1M tokens
$ 0.60in$ 3.00out
StreamingTool callingJSON outputImage inputThinking mode · can be turned off

What this model is good at

What the vendor positions it for, and which of our models to reach for instead.

VendorA foundation model for Agentic Engineering and long-range system work.source

Best for
  • System engineering · Targets backend refactoring, deep debugging and long-range planning.(vendor claim)source

Neighbouring models
  • z-ai/glm-5.2successor —GLM-5.2 extends the family to a full 1M-token context.
Compare them side by side →

Pricing and billing

Tiered pricing: the rate changes once the input passes the threshold.

Price / 1M tokens by input sizeInput < 32.0KInput ≥ 32.0K
Input$ 0.60$ 0.80
Output$ 3.00$ 3.40
Cache read$ 0.16$ 0.20
Cache write$ 0.60$ 0.80
Estimate a request

At this input size you are on the Input < 32.0K tier.

$ 0.0120
Estimated cost per request
10.0K × $ 0.60
+ 2.0K × $ 3.00
≈ $ 12.00 per 1,000 requests

Capabilities and limits

What CrossModel guarantees across every route this model can take right now.

Context window
200.0K tokens
Max output
128.0K tokens
Input / output modalities
Text → Text
Streaming
Supported
Tool calling
Supported
Structured output (JSON)
Supported
Image input
Not supported
Thinking mode
Supported· can be turned off
Available endpoints
/v1/chat/completions · /v1/responses · /v1/messages
First-party sources:Specsdocs.z.ai 1huggingface.co 2Capabilitiesdocs.z.ai 1docs.z.ai 2

Published benchmarks

Scores the vendor reported, with the evaluation setup each one came from.

Agentic coding
  • Terminal-Bench 2.0
    pass_rate·Z.AI · 2026-02-12setup not fully disclosed
    56.2%
Coding
  • SWE-Bench Verified
    resolved_rate·Z.AI · 2026-02-12setup not fully disclosed
    77.8%

Vendor-reported numbers, not CrossModel measurements. Scores are only comparable when the benchmark version, metric and evaluation setup match, so nothing here is averaged or ranked.

Use it in your tools

Point the base URL at CrossModel and paste this model ID — every tool below has a setup guide.

See all integration guides →

Frequently asked questions

What is GLM-5?
GLM-5 is available on CrossModel as z-ai/glm-5. It has a 200K-token context window and can return up to 128K tokens per request.
How much does GLM-5 cost?
Currently $ 0.60 per 1M input tokens and $ 3.00 per 1M output tokens. Cached input is billed at $ 0.16 per 1M.
Does GLM-5 support tool calling and structured output?
Tool calling: Supported · Structured output (JSON): Supported · Image input: Not supported · Streaming: Supported · Thinking mode: Supported
Which endpoint do I call?
OpenAI Chat Completions (/v1/chat/completions), OpenAI Responses (/v1/responses) and Anthropic Messages (/v1/messages) all work — pick whichever your SDK already speaks.
Can I try it without writing code?
Yes. Sign in and open the Playground on this page to chat with the model directly — no API key needed. Usage is billed from your wallet at the normal rate.

Chat first, integrate later

Chat first, then wire it in once you like the answers.