GLM-4.6 API

Advanced version of GLM-4.6 with web search integration and enhanced capabilities

Modalities
TextText
In / Out price
$0.6/$2.2per 1M
Context window
200K tokens
Released
Oct 2, 2025

GLM-4.6 overview

GLM-4.6 by Zhipu AI

GLM-4.6 API delivers advanced reasoning and coding capabilities for complex tasks, agentic workflows, and AI applications.

GLM-4.6 specs

Model ID
zhipu/glm-4.6
Developer
Zhipu AI
Context window
200,000 tokens
Max output
128,000 tokens
Input
Text
Output
Text
API
OpenAI-compatible, base URL https://api.aimlapi.com/v1

GLM-4.6 API Overview

GLM-4.6 is an advanced large language model developed by Zhipu AI (now Z.ai), featuring a state-of-the-art 355 billion parameter Mixture of Experts (MoE) architecture. It is optimized for a broad range of tasks including complex reasoning, coding, writing, and multi-turn dialogue with an extended context window of 200,000 tokens. GLM-4.6 demonstrates industry-leading performance, especially in programming and agentic tasks, making it a top choice for developers and enterprises seeking efficiency and versatility.

Technical Specifications

  • Model Architecture: 355B parameter Mixture of Experts (MoE)
  • Context Window Size: 200,000 tokens (expanded from 128,000 in GLM-4.5)
  • Maximum Output Tokens: 128,000 tokens
  • Efficiency: Approximately 30% more efficient token consumption than previous versions
  • Supported Programming Languages: Python, JavaScript, Java (for coding tasks)

Performance Benchmarks

GLM-4.6 has been rigorously evaluated across authoritative benchmarks demonstrating competitive or superior results against leading models:

  • Real-world Coding Tests: Outperforms similar domestic models in 74 coding scenarios, showing better code correctness and performance.
  • Comparative Efficiency: Consumes approximately 30% fewer tokens for equivalent output, reducing costs and resource needs.
  • Benchmark Results: Comparable to Claude Sonnet 4 and 4.6 on multi-domain NLP benchmarks like AIME, GPQA, LCB v6, and SWE-Bench Verified.
  • Reasoning and Agent Tasks: Strong performance in decision-making and tool-assisted tasks, often matching or exceeding competitors in benchmark tests.
  • Contextual Understanding: Expanded context allows superior performance on tasks requiring deep document analysis and complex instructions.

Key Features and Capabilities

  • Extended Context Handling: With a massive 200K token window, GLM-4.6 can perform detailed long-form text comprehension, multi-step problem solving, and maintain coherent, prolonged dialogues.
  • Superior Coding Performance: Outperforms GLM-4.5 and many domestic competitors in 74 practical coding tests within the Claude Code environment. Excels in front-end development, code organization, and autonomous planning.
  • Advanced Reasoning and Decision Making: Enhanced tool usage capabilities during inference enable better autonomous agent frameworks and search-based task execution.
  • Natural Language Generation: Produces text with improved alignment to human stylistic preferences, excelling in role-playing, content creation (novels, scripts, ads), and multi-turn conversations.

Comparison with Other Models

Vs. GLM-4.5: GLM-4.6 offers noticeable improvements in code generation accuracy and maintains a consistent edge in handling ultra-long context inputs, while retaining strong agentic task performance close to GLM-4.5.

Vs. OpenAI GPT-4.5: GLM-4.6 narrows the gap in reasoning and multi-step task accuracy, leveraging its much larger context window; however, GPT-4.5 still leads in raw task precision on some standardized benchmarks.

Vs. Claude 4 Sonnet: While Claude 4 Sonnet excels in coding and multi-agent efficiency, GLM-4.6 matches or surpasses it in agentic reasoning and long-document comprehension, making it stronger for extended-context applications.

Vs. Gemini 2.5 Pro: GLM-4.6 balances advanced reasoning and coding capabilities with enhanced long-form document understanding, whereas Gemini 2.5 Pro is more focused on optimizing individual coding and reasoning benchmarks.

API Integration

Accessible via AI/ML API. Documentation: available here.

Use cases

  • Long-context document analysis and summarization
  • Complex multi-step reasoning and problem solving
  • Real-world programming and code generation in multiple languages
  • Natural language content creation including creative writing and scripts
  • Chatbots with sustained, coherent multi-turn conversations
  • Agentic systems with tool use and autonomous decision making
  • High-volume industrial-scale applications requiring token-efficient models

Capabilities

  • Function calling
  • Streaming
  • Structured outputs
  • Reasoning

GLM-4.6 benchmarks by Artificial Analysis

See how GLM-4.6 compares in generation speed and latency. Data retrieved Nov 3, 2026.

Speed

Output tokens / second

Benchmark results

Compare 13 models available on AI/ML API across 5 independent benchmarks.

Humanity's Last Exam

Expert-written questions across academic subjects.

GLM-4.6 API pricing

GLM-4.6 pricing in US dollars
UsagePriceUnit
Input$0.61M tokens
Output$2.21M tokens
Cached input$0.111M tokens

Prices from the AI/ML API price list, checked on Nov 4, 2026.

GLM-4.6 vs other models: token prices

AI/ML API input and output rates for 5 models, per million tokens.

AI/ML API model prices in USD per million tokens
ModelInputOutput
GLM-4.6$0.6$2.2
GLM-5.3-Flash$0.15$0.5
GLM 5.3 FlashX$0.37$1.25
GLM-5.3$1.4$4.4
GLM 5.2 Fast Preview$3.5$11

How to use the GLM-4.6 API

View docs

Build with your agent

Give your agent the model details, code and documentation.

1Get your API key

Create API key
export AIMLAPI_KEY="8f2b4c7d9a1e6b3f…"

2Make your first request

curl 'https://api.aimlapi.com/v1/chat/completions' \
  -H "Authorization: Bearer $AIMLAPI_KEY" \
  -H 'Content-Type: application/json' \
  -d '{
  "model": "zhipu/glm-4.6",
  "messages": [
    {
      "role": "user",
      "content": "Write a haiku about the ocean."
    }
  ]
}'

Related articles

All posts

GLM-4.6 FAQ

What is the context window of GLM-4.6?

GLM-4.6 has a 200,000 tokens context window and can return up to 128,000 tokens.

What inputs and outputs does GLM-4.6 support?

GLM-4.6 takes text as input and returns text.

What is the model ID for GLM-4.6?

Use zhipu/glm-4.6 as the model id. Requests go to https://api.aimlapi.com/v1/chat/completions.

When was GLM-4.6 released?

GLM-4.6 became available on October 2, 2025.

How much does GLM-4.6 cost?

GLM-4.6 costs $0.6 input and $2.2 output per 1M tokens on AI/ML API, billed as you go with no subscription.

Does GLM-4.6 support streaming?

Yes, GLM-4.6 can stream responses as they are generated.

Who created GLM-4.6?

GLM-4.6 was built by Zhipu AI.

Start building with GLM-4.6

GLM-4.6 API

zhipu/glm-4.6

Build with your agent

Give your agent the model details, code and documentation.

1Get your API key

Create API key
export AIMLAPI_KEY="8f2b4c7d9a1e6b3f…"

2Make your first request

curl 'https://api.aimlapi.com/v1/chat/completions' \
  -H "Authorization: Bearer $AIMLAPI_KEY" \
  -H 'Content-Type: application/json' \
  -d '{
  "model": "zhipu/glm-4.6",
  "messages": [
    {
      "role": "user",
      "content": "Write a haiku about the ocean."
    }
  ]
}'