413 Content Too Large: what it means and what to do
A 413 means the thing you sent is simply too big for the server's limits. RFC 9110 renamed this code from Payload Too Large to Content Too Large; older servers, frameworks, and error pages still use the old name, and they mean the same thing. The official definition is that the server is refusing to process a request because the request content is larger than the server is willing or able to process. Uploads are the everyday trigger: a photo, video, or attachment that crosses a size cap somewhere between you and the application.
If you are just visiting a site
- Make the file smaller. Compress photos and videos before uploading, or send fewer files at once. Most upload limits sit between 2 MB and 100 MB depending on the service.
- Split the upload. If the service allows multiple files, send them in smaller batches. Five files in one request can exceed a limit that each file passes individually.
- Check the service's stated limit. Upload pages and help docs often publish the maximum. There is no trick that gets a 200 MB file through a 25 MB limit.
- Try a wired or stronger connection for borderline uploads. It does not change the limit, but large uploads that stall can also die in ways that look like size errors.
If it is your site or your API
- Know every limit in the chain. Your app framework, your web server (nginx client_max_body_size, Apache LimitRequestBody), and your CDN each enforce their own cap, and the lowest one wins. The mismatch between them is the usual source of surprise 413s.
- Align the limits and the messaging. If the product promises 100 MB uploads, every layer must allow a bit more than 100 MB, and the upload page should state the real number.
- Return a helpful body. Telling the caller the maximum size in the 413 response turns a guessing game into a one-step fix.
- Consider chunked or resumable uploads if users routinely send large files. It sidesteps several limits and survives flaky connections.
Visitors: the file is too big for that service's limit, full stop. Owners: when users report 413s on files your product claims to support, one layer of your stack disagrees with the others.
Common questions
Is 413 Payload Too Large the same as 413 Content Too Large? Yes. RFC 9110 renamed the status in 2022 from Payload Too Large to Content Too Large. Servers and documentation still use both names for the identical code and meaning.
What is the maximum upload size before a 413? There is no universal number. It is set by each service, and often by several layers of its stack. Email attachments commonly cap near 25 MB, web forms anywhere from 2 MB up, and dedicated file services much higher. The service's own help pages state its limit.
Related errors