**TL;DR:** A 404 means the endpoint path or a resource ID in the URL is wrong, or the resource (including a model) is gone. Check the endpoint path against the API reference. Check every resource ID embedded in the URL: message IDs, batch IDs, file IDs, model names.

## The fix

1. Check the endpoint path against the API reference. Typos in the path are the top cause.

2. Check every resource ID embedded in the URL: message IDs, batch IDs, file IDs, model names. One stale ID from a cached list 404s the whole call.

3. If the 404 names a model, check the model deprecations page. Retired models fail on request; a model ID that worked last quarter may be retired now. Migrate to the recommended replacement.

4. In the SDKs, catch the typed exception (for example anthropic.NotFoundError in Python) rather than string-matching the message. Catch the most specific exception class first, then the general ones.

5. Retry policy: a 404 never clears by retrying. Fix the identifier.

6. Audit hardcoded model IDs on a schedule. Retirement gives at least 60 days notice for public models; the notice only helps if someone reads it.

7. The error response always includes a request_id. Include it if you need support, since a 404 you cannot explain is worth one ticket, not ten retries.

## When to use this

- You are seeing this exact error message; match the block above, not just part of it.
- The failing call matches the scenario in the title: Anthropic 404 not_found_error.
- You want the fastest verified fix before digging through logs.

## When not to use this

- Your error text differs from the block above; close cousins often have different causes.
- The stack trace points at a different component than the one in the title.
- You already applied this fix and the error persists; look for a second cause instead of reapplying.

## Compatibility

- Not pinned to a specific version; follows current Anthropic behavior.