Contents
When you are working in Claude Code or the Anthropic API, your work can suddenly grind to a halt with an error like this:
API Error: 400 Output blocked by content filtering policy
# The raw response looks like this:
{"type":"error","error":{"type":"invalid_request_error",
"message":"Output blocked by content filtering policy"}}
"The output was blocked by the content-filtering policy" — in other words, it isn't your input, but the output that Claude was about to return, that Anthropic's safety filter stopped mid-flight. The HTTP status is 400, and the type is invalid_request_error. This is not a usage limit and not a context overflow — what got caught is "what it tried to output."
Three key takeaways up front. ① The cause is almost always a judgment that you were "trying to reproduce existing copyrighted material verbatim." Claude is designed to generate new content, and it has a safety mechanism that stops the wholesale copying of existing text. ② That said, false positives are common — generating the full text of standard licenses like MIT/Apache, or "match this existing page" work, can trip it even with no ill intent. ③ The core fix is to "not make the model copy verbatim" — fetch things like licenses with a tool, steer your prompts toward "transforming, summarizing, and generating new content," and if you fall into a retry loop, stop once and rephrase. In this article, drawing on official information and real-world bug reports, we lay out the cause, the false-positive patterns, the fixes, and how it differs from similar errors.
Where exactly it stops
— it's the "output," not your input, that the filter holds back
What stops is stage ③, the output stage. It is neither an input that's too long (Prompt is too long) nor a usage limit.
Output that "creates something new" passes; output that "copies existing material wholesale" is what tends to get caught.
1. What this error is actually telling you
The Anthropic API has a safety system that checks both the input (what you send) and the output (what Claude returns). Output blocked by content filtering policy means, as the name says, that the filter on the "output" side stopped the content Claude was about to return. The API response comes back as HTTP 400 / invalid_request_error, and in Claude Code the session displays API Error: 400 Output blocked by content filtering policy and halts.
Key point: this is different from the model politely declining in conversational prose (a refusal). A refusal comes back as text, but this 400 makes the API call itself error out. That's why Claude Code can't receive a response and the process is interrupted.
The important thing is that this is not a "bug" but "the safety mechanism doing its job." So it is not the kind of thing that "a restart will fix" — the proper approach is to reconsider what you were asking it to output. That said, as we'll see below, false positives are quite common, so when it fires during legitimate work, you can usually get around it by rephrasing or changing your approach.
2. Why it happens — the mechanism that stops copyrighted "reproduction"
According to Anthropic's official explanation, the filter's main purpose is to prevent existing material from being duplicated or regurgitated verbatim. The company frames Claude's role as "generating new content and ideas rather than reproducing existing content," and additionally cites its policy prohibiting uses that infringe intellectual-property rights.
In other words, the filter tends to fire when it judges the output to be "too close to a verbatim copy of text that already exists in the world." Concretely, cases like these:
Asking it to "write out as-is" the full text of a license like MIT / Apache-2.0 / BSL / MPL, or a standard code of conduct or template, is easily judged to be wholesale copying of existing material.
Instructions that copy from an external existing source, such as "edit the file so it exactly matches this online resource" or "reproduce it just like the original article."
Bulk quotation or full reprinting of existing API docs, books, or articles. Summarizing or restructuring tends to pass, but verbatim copying gets caught.
Caution: the official note also states clearly that "if you are genuinely trying to extract copyrighted material and receive this warning, repeating the attempt may lead to warnings or account suspension/termination." Do not try to work around it for the purpose of deliberate copying. What we cover here is strictly false positives during legitimate work.
3. Common false-positive patterns
The company itself acknowledges the existence of false positives, noting that "some users encounter this refusal/error even without any intent to duplicate." Indeed, the Claude Code issue tracker has many reports of it firing during "zero ill-intent" work like the following.
It halts during the standard setup of creating a LICENSE file, CI config, and community-health files (CODE_OF_CONDUCT, etc.).
Partway through a comparison task like "reconcile against the online list and fix the differences," the output drifts close to the existing list and it fires.
There are cases where it halts with a 400 after running for 1–2 hours and is misdiagnosed as a "token limit." The real cause is the output filter.
A known quirk on the Claude Code side: when it hits this error, it can enter a retry loop, attempting the same output over and over and failing to move forward. It can loop for a long time with zero files written, making the cause easy to misread. Once you notice the loop, stopping it manually comes first (next section).
4. How to fix it right now
The response differs between "the safety mechanism worked correctly" and "a false positive," but for legitimate work the following order avoids it with high probability.
Don't have the model write boilerplate full texts like licenses — fetch them with a tool instead. E.g., npx license mit, paste from choosealicense.com, or specify a template with gh repo create.
Instead of "reproduce as-is," change it to "summarize," "restructure," "rewrite in your own words," or "output only the diff." Simply not demanding a verbatim match often gets it through.
If Claude Code keeps retrying the same output, interrupt it with Esc. Don't resend the same instruction — rephrase first, then resume.
To isolate which output is the trigger, break a big bulk generation into smaller pieces. Comparing a working setup one variable at a time makes the cause easier to pin down.
If it keeps appearing despite legitimate work, contact Anthropic support. The company also welcomes feedback to improve the filter.
Rephrasing examples (same goal, but more likely to pass)
❌ "Write the full text of the MIT license into LICENSE as-is."
✅ "I want to create a LICENSE. Run npx license mit to generate it."
❌ "Paste this official documentation verbatim, word for word."
✅ "Read this official documentation and give me a bulleted
summary of the key points in your own words. No verbatim
copy of the original is needed."
5. How to tell it apart from similar-looking errors
Even when it all looks like "it stopped," the cause can be identified from the message. Distinguish by status and keywords.
| Message / type | Real cause | Fix |
|---|---|---|
| Output blocked by content filtering policy (400) | Output judged to be reproduction of existing copyrighted material | Avoid verbatim copy; rephrase / fetch with a tool |
| Prompt is too long (400) | Input exceeds the context window | /compact · /clear (explainer) |
| usage limit reached | You've used up your plan's quota | Wait for reset / upgrade plan (explainer) |
| 529 Overloaded / 500 | Temporary server-side overload or outage | Wait a bit and retry (explainer) |
| Output cut off mid-way | Hit the max_tokens output limit |
Raise the output limit / split generation |
When in doubt, judging by the message string itself is the reliable way. If it says content filtering policy, it's this article's topic; too long means input overflow; usage limit means you're out of quota. Claude Code errors in general are also collected in Common Claude Code errors and how to fix them.
6. Prevention checklist
- For licenses and boilerplate documents, don't have the model write them — fetch them with a tool or template
- For existing material, ask to "summarize, restructure, or put it in your own words" rather than "reproduce"
- Drop phrases like "word for word," "as-is," and "exactly match" from your prompts
- Break big bulk generations into smaller pieces so you can isolate the triggering output
- When it stops with a 400, read the message string first — to prevent misreading the cause (misdiagnosing it as a token limit)
- When you notice a retry loop, stop it with Esc and rephrase before resuming
- Report false positives during legitimate work to support to help improve the filter
Summary
API Error: 400 Output blocked by content filtering policy means that — it's not a usage limit and not a context overflow, but the safety filter holding back the "output" Claude was about to return. Its focus is preventing verbatim reproduction of existing copyrighted material, and generating standard licenses or doing "match this existing material" work often trips a false positive with no ill intent. The core fix is simple: don't make the model copy verbatim; replace it with generation, summarization, or tool-based fetching. And when it stops with a 400, read the message string first so you don't misread the cause — that alone gets most cases moving forward again.
FAQ
Q. Does this mean my account has been flagged?
A. Not if it's a one-off false positive. That said, the company states clearly that repeatedly trying to extract copyrighted material can lead to warnings or account suspension. There's no need to panic over a single occurrence during legitimate work.
Q. Isn't it inconvenient that it can't even write the MIT license?
A. The full text of a license is "existing boilerplate text," so rather than having the model copy it verbatim, fetching it via npx license mit or from choosealicense.com is faster and more reliable. It also avoids the false positive.
Q. How is this different from a token limit (Prompt is too long)?
A. Completely different. too long is about the size of the input exceeding the window, addressed with /compact and the like. This content filtering policy is about the content of the output, and reducing size won't fix it. See more here.
Q. No matter what I do, it stops during legitimate work. What now?
A. If it recurs even after you rephrase prompts toward generation/summarization and split the task, report it to Anthropic support with a request id. The filter keeps improving, and sharing false positives is the fastest path to a resolution.