Back to Models
qwen logoQwen
qwen4-max

Qwen4 Max

Qwen4 Max is the flagship model in Alibaba's Qwen4 series. It accepts text, image, and video input and returns text, with a 1M-token context window and reasoning enabled by default....

11/16/2026
1,000,000 tokens
Input: $1.50/M
Output: $4.48/M

Specifications

Modalities

Input
text
image
video
Output
text

Supported Parameters

frequency_penalty
include_reasoning
logprobs
max_tokens
presence_penalty
reasoning
reasoning_effort
response_format
seed
stop
structured_outputs
temperature
tool_choice
tools
top_k
top_logprobs
top_p

Max Output Tokens

131,072

Reasoning Configuration

Default
Thinking on (effort: high)
Selectable effort levels
xhigh
high
low
none
Turning thinking off
Possible (reasoning.enabled: false)

How to control thinking, and what it costs

Data policy

Prompt retention
Unknown: we could not confirm
Training
Not used for training

"Unknown" does not mean "safe". It means we could not confirm it.

Whether a provider trains on prompts is a declared value from our terms with them. Retention is determined from the upstream listing for every host this model can reach. Neither is guessed.

Code Examples

curl https://api.fastmetal.ai/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d '{
    "model": "qwen4-max",
    "messages": [{"role": "user", "content": "Hello!"}]
  }'

How Qwen4 Max actually answers

Real responses to our standard prompts, recorded on FastMetal.

Count the number of 'r's in 'strawberry'

Count the number of 'r's in 'strawberry'. Explain your reasoning step by step.

## Answer: There are **3** r's in "strawberry." ### Step-by-step reasoning **Step 1: Write out the word letter by letter.** s – t – r – a – w – b – e – r – r – y **Step 2: Number each position and check for 'r'.** | Position | Letter | Is it 'r'? | |---|---|---| | 1 | s | no | | 2 | t | no | | 3 | **r** | ✅ yes (1) | | 4 | a | no | | 5 | w | no | | 6 | b | no | | 7 | e | no | | 8 | **r** | ✅ yes (2) | | 9 | **r** | ✅ yes (3) | | 10 | y | no | **Step 3: Tally the matches.** One 'r' appears in the first part, "st**r**aw," and two more appear together in the second part, "be**rr**y." 1 + 2 = **3** **Why people often miscount:** The word splits naturally into "straw" + "berry," and the…
11.8s response416 output tokens

Debug This Error

I'm getting the following error in my Node.js application: TypeError: Cannot read properties of undefined (reading 'map') at UserList (/app/components/UserList.js:12:25) at renderWithHooks (/app/node_modules/rea…

## What's causing it `users` is `undefined` when `UserList` renders, so `users.map(...)` throws. Destructuring `{ users }` from props doesn't create a default — if the parent doesn't pass `users` (or passes `undefined`), you get exactly this error. The stack trace confirms it's happening during render (`renderWithHooks`), not in an event handler, which means the very first render already has no data. ## The three usual culprits **1. Data is still loading (most common)** ```jsx function Parent() { const [users, setUsers] = useState(); // undefined on first render useEffect(() => { fetch('/api/users') .then(r => r.json()) .then(setUsers); }, []); return <UserList…
16.6s response802 output tokens

Code Review

Please review the following Python function and suggest improvements for readability, performance, and best practices: def get_data(url, retries=3): import requests import time for i in range(retries):…

## Overall assessment The function works on the happy path, but it has one genuine bug (a bare `except` that swallows *everything*, including data-shape errors), and its failure semantics are ambiguous: `[]` means both "no active items" and "the service is down." Below are the issues ordered roughly by impact, then a refactor. --- ## Correctness & robustness **1. Bare `except:` is the biggest problem.** It catches `KeyboardInterrupt` and `SystemExit` (so Ctrl-C during a retry storm won't work), and it hides programming errors. Catch `requests.ConnectionError`, `requests.Timeout`, and `requests.HTTPError` explicitly. **2. Data processing inside the retry loop causes pointless retries.**…
121.9s response5826 output tokens

Compare these answers side by side with other models →

Frequently asked questions

How much does the Qwen4 Max API cost?
On FastMetal, Qwen4 Max is billed per token: $1.50 per 1M input tokens and $4.48 per 1M output tokens on a US-dollar account, before tax. Usage is drawn from a prepaid balance; there is no subscription or monthly fee.
Can I call Qwen4 Max with the OpenAI SDK?
Yes. Point base_url at https://api.fastmetal.ai/v1 and pass "qwen4-max" as the model; existing OpenAI-style code works unchanged, including streaming, tool calls and structured output.
What is the context window of Qwen4 Max?
1,000,000 tokens, shared between the prompt and the response.
What do I need to try Qwen4 Max?
Create an account and add credit; the model is then available both in the browser chat and over the API. There is no contract or minimum spend.

Try Qwen4 Max right now

Qwen4 Max is available on FastMetal through one API key. Start in the browser, or call it from the OpenAI SDK.