current position:Home>Nginx error 413 Request Entity Too Large solution

Nginx error 413 Request Entity Too Large solution

2022-08-06 18:38:19As for why

Nginx will report a 413 error when uploading a large file. This article records the solution.

Problem Reason

  • Nginx default upload file size limit is 1M
  • If you want to adjust the upload file size limit, you need to adjust the configuration


  • Modify the file /etc/nginx/nginx.conf
  • Add the following configuration in http{}:
client_max_body_size 512M;

  • Restart nginx
sudo systemctl restart nginx# orservice nginx restart


copyright notice
author[As for why],Please bring the original link to reprint, thank you.

Random recommended