request entity too large

What is "Request Entity Too Large" error?

"Request Entity Too Large" is an HTTP error that occurs when a client sends a request to a server that exceeds the maximum size limit set by the server. This error message indicates that the server is unable to process the request because the data sent by the client is too large.

Causes of "Request Entity Too Large" error

  • The client sent a file that is too large for the server to handle.
  • The server has a limit on the size of requests it can handle and the client exceeded it.
  • The upload_max_filesize, post_max_size, or memory_limit values in the php.ini file are set too low.

How to fix "Request Entity Too Large" error

There are several ways to fix this error, depending on the cause of the error:

1. Increase the upload_max_filesize, post_max_size, and memory_limit values in php.ini file


    upload_max_filesize = 64M
    post_max_size = 64M
    memory_limit = 128M

2. Configure your web server

If you're using Nginx or Apache as your web server, you can configure it to allow larger file uploads. Here's how to do it for Nginx:


    client_max_body_size 64M;

And here's how to do it for Apache:


    LimitRequestBody 67108864

3. Use a third-party file transfer service

If increasing the max file size limit and configuring your web server doesn't work, you can use a third-party file transfer service like Dropbox or Google Drive to share large files.

Subscribe to The Poor Coder | Algorithm Solutions

Don’t miss out on the latest issues. Sign up now to get access to the library of members-only issues.
[email protected]
Subscribe