Seeing the 413 Request Entity Too Large WordPress error? We’ll calm down your anxiety right away. Although concerning, it’s not a fatal error like the white screen of death in WordPress. The error commonly occurs when you upload a file that’s over the maximum upload size set in WordPress. This is intentional. That way, you cannot upload plugins, themes, or media files that are too large. This would significantly slow down your website, crash it, or lead to hosting overload. But what if you can’t find an alternative or compress the file enough? That’s why we intend to teach you how to fix the 413 Request Entity Too Large error in WordPress.
A step-by-step guide to solve the 413 Request Entity Too Large error in WordPress
We will assume you tried to compress the file or tried to find an alternative that takes less space. Here are multiple ways to get rid of the 413 Request Entity Too Large WordPress error:
1. Increase the maximum upload file size limit
For this to work, you first need to know how to access your WordPress website via FTP. You’ll need an FTP client or use the cPanel on your hosting website. After that, you can proceed with following the steps to increase the maximum file upload size in WordPress. If you prefer a few other alternatives, mainly installing a WordPress plugin by accessing the WordPress Admin Section, that’s possible too.
2. Can you access your website in Nginx?
If you follow the steps above and still get the error, you also need to configure Nginx (pronounced engine-ex) as well. First, check that your hosting supports it and that you can access it. It’s best if you contact the 24/7 customer support or write a ticket. You’ll need a third-party app, also known as SSH client or SSH Terminal. We recommend PuTTy for Windows, although you can use it on Linux and macOS. Keep in mind that both Linux and macOS have a built-in SSH client called OpenSSH.
To start, check your hosting cPanel to see if there’s an option called SSH Access or SSH Accounts under Advanced. Then look for an option called SSH Details under the Server tab. With these two, you should be able to get all you need – an SSH username, SSH password, Server IP Address, and SSH port. Open the client and log in using this information.
- You’ll see a terminal much like Command Prompt, Windows PowerShell, or Terminal on macOS or Linux.
- We recommend using the vi text editor. The other options are Nano or Joe’s Own Editor if you seek an alternative.
- Type this command in the Terminal:
- Now, at the bottom of the file, type:
# set client body size to 8M #
- You can later increase 8MB if you’re still getting the error.
- Save the changes by pressing : (colon) and x then press Enter.
- To reload the Nginx after the change, type:
service nginx reload
- You can also try:
/sbin/nginx -s reload
- The error should be fixed now.
3. Fix the problem in Apache
Apache is the most popular webserver and hostings usually combine it with Nginx to get the best of both worlds. Lucky for you, you don’t need to be tech-savvy as you would with Nginx, because Apache checks your .htaccess file for configuration before it processes a request.
- Access your website via FTP.
- Right-click on the .htaccess file (it will be in the root directory of your website.)
- Select View/Edit.
- Search for “LimitRequestBody” using Ctrl (Control) + F.
- If it isn’t there, and you used method 1 to edit the .htaccess file, add this line underneath those you added previously:
- If it was there in the first place, you just need to edit the number.
- This is an example that will restrict the request size to 100 Megabits. Feel free to reduce or increase it, based on the size of your files.
Those were the instructions to fix the 413 Request Entity Too Large error in WordPress. If you are scared or overwhelmed by them, it’s best you contact your hosting Customer Support. There’s no shame in asking for help when you need it!