GLM 5.1

by Z.ai

Released 6 days after GLM-5V-Turbo · All Z.ai releases

GLM-5.1 is Z.ai's flagship open-weight model, released in April 2026 with a sparse Mixture of Experts architecture totaling 754 billion parameters and roughly 40 billion active per token. It supports a 202,752-token context window and can generate up to 128,000 tokens per response, suiting it to long document analysis and extended code generation. Built for autonomous software engineering, GLM-5.1 reports a state-of-the-art 58.4 on SWE-Bench Pro, ahead of Claude Opus 4.6 (57.3) and GPT-5.4 (57.7), and is designed for multi-step agentic workflows where it can sustain a single task for up to eight hours across planning, execution, testing, and refinement. Rather than single-pass generation, it iteratively drafts, evaluates, and revises solutions toward production-ready code. Released under the MIT license on Hugging Face, GLM-5.1 supports function calling, thinking modes, structured output, context caching, and tool use, and can be self-hosted, fine-tuned, and deployed commercially without restrictive licensing terms. Stronger on coding and agentic tasks than on broad general reasoning, GLM-5.1 also handles multilingual content and supports streaming output during tool execution for real-time development feedback.

Call GLM 5.1 on Opper with the OpenAI SDK. Sign up without a credit card. Get started

Key info

Input
Output
Features
Context window
203K
Max output
131K
Input price
$0.89 /1M$0.18 cache read
Output price
$3.58 /1M
Released
  • EU residency available
  • US residency available
  • Zero data retention on pay-as-you-go
  • GDPR DPA available

Available routes

GLM 5.1 runs on 8 different routes through the Opper gateway. Compare residency, zero data retention and training posture at a glance, with full data-handling detail per route below.

ProviderRegionZero data retentionTrainingInputOutputCache read
MultiNo$0.89$3.58$0.18
Multi—Not established—$1.40$4.40$0.26
USNo$1.05$3.50$0.20
USNo$1.30$4.30$0.26
MultiNo$1.40$4.40Input price
USNo$1.38$4.40Input price
EUNo$1.40$4.40$0.35
MultiNo$1.40$4.40$0.26

Uptime and availability

GLM 5.1 runs on 4 independently monitored routes through the Opper gateway. A direct integration leaves you on one of them, the gateway serves whichever is healthy.

100%effective uptime, last 30 days
Averaged across these routes on their own, a single provider reached 99.55% over the same window.
Daily status through the gateway, which serves each request from whichever route is healthy.
4 monitored providers serve GLM 5.1.

Measured over the last 30 days from each provider's official status feed via StatusGator. Refreshed hourly. 4 further routes for this model are not on the board yet and are not counted above. See uptime for every provider Opper monitors.

Data handling per route

Each route hosting GLM 5.1 has its own privacy posture, residency, and GDPR terms. Postures are maintained by Opper with a last-verification timestamp.

Alibaba Cloud — Multi-region

Zero data retention with abuse monitoring: prompts and outputs are kept for abuse monitoring only, for a window the provider does not state, and are not used for training. No training on customer data. GLOBAL; SCCs; DPA available.

Zero data retention
With abuse monitoring, window not stated.
Training
No training on customer data.
Logging
Abuse monitoring
Abuse monitoring
On by default, holds flagged content
Caching
Content cached for replay
GDPR DPA
DPA available
Transfer mechanism
SCCs

Baidu Qianfan — China🇨🇳

Zero data retention posture is not established for this route. Training posture pending review. GLOBAL; unknown.

Zero data retention
Not established.
GDPR DPA
No DPA
Transfer mechanism
unknown

DeepInfra — United States🇺🇸

Zero data retention: nothing is logged, held for abuse monitoring or used for training. No training on customer data. US; unknown; DPA available.

Zero data retention
Yes. Nothing is logged, held for abuse monitoring or used for training.
Training
No training on customer data.
Logging
None
Abuse monitoring
No classifier
GDPR DPA
DPA available
Transfer mechanism
unknown

DigitalOcean — United States🇺🇸

Zero data retention with abuse monitoring: nothing is logged or used for training; content flagged by abuse monitoring is held for review. No training on customer data. US; dpf sccs; DPA available.

Zero data retention
With abuse monitoring, flagged content held.
Training
No training on customer data.
Logging
None
Abuse monitoring
Always on, holds flagged content, stored in United States
Caching
Content cached for replay
Subprocessor access
No subprocessor reads content
GDPR DPA
DPA available
Transfer mechanism
dpf sccs

Nebius — Multi-region

Content is retained: provider logging. No training on customer data. GLOBAL; SCCs; DPA available.

Zero data retention
Retained: provider logging.
Training
No training on customer data.
Logging
Other
Abuse monitoring
No classifier
GDPR DPA
DPA available
Transfer mechanism
SCCs

Novita — United States🇺🇸

Zero data retention: nothing is logged, held for abuse monitoring or used for training. No training on customer data. US; SCCs; DPA available.

Zero data retention
Yes. Nothing is logged, held for abuse monitoring or used for training.
Training
No training on customer data.
Logging
None
Abuse monitoring
On by default, keeps nothing
GDPR DPA
DPA available
Transfer mechanism
SCCs

TensorX — European Union🇪🇺

Zero data retention: nothing is logged, held for abuse monitoring or used for training. No training on customer data. EU; DPA available.

Zero data retention
Yes. Nothing is logged, held for abuse monitoring or used for training.
Training
No training on customer data.
Logging
None
Abuse monitoring
No classifier
Caching
Content cached for replay
GDPR DPA
DPA available
Transfer mechanism
Not applicable — data stays in EU

Z.ai — Singapore🇸🇬

Zero data retention with abuse monitoring: nothing is logged or used for training; content flagged by abuse monitoring is held for review. No training on customer data. GLOBAL; unknown; DPA available.

Zero data retention
With abuse monitoring, flagged content held.
Training
No training on customer data.
Logging
None
Abuse monitoring
On by default, holds flagged content
Caching
Content cached for replay
Subprocessor access
Subprocessors may read content
GDPR DPA
DPA available
Transfer mechanism
unknown

Benchmarks

Independent benchmark scores — composite indices for reasoning, coding, and math, plus individual eval scores where available.

Intelligence Index26.1
Coding Index55.8
Reasoning & knowledge
GPQA Diamond
87%
Humanity's Last Exam
30%
Long-context reasoning
74%
Coding
SciCode
45%
Agentic & tool use
Terminal-Bench Hard
43%
τ²-Bench Telecom
98%
Math & instruction following
IFBench
76%

Get started

Call GLM 5.1 through the Opper gateway with one API key. Opper is drop-in compatible with the OpenAI, Anthropic and Google AI SDKs.

GLM 5.1 is a premium model on Opper. Sign up needs no credit card: you get an API key straight away and the free models work in the playground and the API. Add a card to use premium models, pay-as-you-go with no minimum.

Set it up with your agent

Copy this and paste it into a coding agent like Claude Code, Cursor or Codex and it'll wire up Opper for you.

Or call it directly

import OpenAI from "openai";
const client = new OpenAI({
apiKey: process.env.OPPER_API_KEY,
baseURL: "https://api.opper.ai/v3/compat",
});
const completion = await client.chat.completions.create({
model: "glm-5.1",
messages: [{ role: "user", content: "Hello" }],
});
console.log(completion.choices[0].message.content);

Compare GLM 5.1 with…

Side-by-side on privacy, EU hosting, pricing, and benchmarks.

Other models from Z.ai

Start building with 700+ models

One API key. Every major provider. Up and running in minutes.

Get startedView Documentation