DevToolPal
EN
4xx Client errors

413 Content Too Large

What it means

The request body is larger than the server is willing or able to process. Formerly called Payload Too Large.

Common causes

  • Upload exceeds nginx client_max_body_size (default 1 MB)
  • PHP upload_max_filesize or post_max_size too small
  • API gateway or serverless body limits

How to fix it

As a client or visitor

Compress or split the upload, or use the service's resumable or multipart upload API.

As the site or API owner

Raise limits at every layer: proxy (client_max_body_size), app framework, and gateway. Report the limit in the error message.

Example response

HTTP/1.1
HTTP/1.1 413 Content Too Large
Date: Tue, 07 Oct 2025 09:30:00 GMT
Server: nginx
Connection: close
Content-Type: application/problem+json

{
  "type": "about:blank",
  "title": "Content Too Large",
  "status": 413,
  "detail": "Uploads are limited to 10 MB."
}

Specification

RFC 9110 §15.5.14

FAQ

› How do I fix 413 in nginx?

Increase client_max_body_size in the http, server or location block, for example client_max_body_size 50m; then reload nginx.

› Why do I still get 413 after raising the app limit?

Another layer, such as a reverse proxy, CDN or load balancer, has its own lower limit.