Model behaviour
Claude API returns different output than Claude.ai for the same prompt
Updated 8/13/2026
What's happening
Claude.ai is a product built on top of the API. It supplies its own system prompt, tool access and sampling defaults, so identical user text can produce different output.
Fix it
- Match the model version exactly — the app may run a newer snapshot.
- Add an explicit system prompt describing role, format and constraints.
- Set temperature and max_tokens deliberately rather than relying on defaults.
- Reproduce any file or search context the web app had access to.
- Pin a dated model snapshot in production so behaviour stops drifting.
Still stuck?
If output varies between identical API calls, lower temperature and specify the response format explicitly.
Quick fixes
- Claude is down or not loading
- Claude Pro billing or payment problem
- Can't sign in to Claude