1. Home
  2. Knowledge Base
  3. Frequently Asked Questions
  4. BuddyBoss Web
  5. Wordpress Setting
  6. How to Fix “413 Request Entity Too Large” Error in WordPress

How to Fix “413 Request Entity Too Large” Error in WordPress

Introduction

The 413 Request Entity Too Large error occurs when you attempt to upload a file that exceeds your server’s configured upload size limit. This commonly happens when installing large plugins, themes, or media files via the WordPress dashboard.

Increase PHP Upload Limits via functions.php

  1. In your WordPress admin, go to Appearance > Theme Options > Functions.php.

Add the following lines at the bottom of the file (below any existing code):

// Increase upload and execution limits
@ini_set( 'upload_max_size' , '128M' );
@ini_set( 'post_max_size', '256M' );
@ini_set( 'max_execution_time', '300' );
  1. Click Update File to save your changes.

These directives raise your upload allowance to 128 MB, increase the maximum POST size, and extend the script execution time to 300 seconds

Ask Your Host to Raise Limits

If editing functions.php isn’t possible or the changes don’t take effect, contact your hosting provider and request they increase your PHP settings (upload_max_filesize, post_max_size, and max_execution_time) to values that accommodate your needs.

Troubleshooting and FAQs

Q: I still see the 413 error after updating functions.php—what next?
A: Some hosts ignore ini_set() calls. In that case, ask your host to update PHP configuration (php.ini) or use .htaccess/server settings.

Q: Can I set higher values than shown?
A: Yes. Adjust ‘128M’, ‘256M’, and ‘300’ to match your largest expected upload and desired execution time.

Q: Will this affect performance?
A: Higher limits allow larger uploads but don’t impact performance unless you actually upload big files. Long scripts may tie up server resources—use sensible values.

Q: I don’t have access to Theme Options > Functions.php—what can I do?
A: Use FTP or your host’s file manager to edit your child theme’s functions.php directly, or employ a site-specific plugin for custom snippets.

Was this article helpful?

Related Articles

To speak to our Agency consultant, fill in the form found at our Contact Page.

  • Get Started

    Enter your name and email address to get started with your project...

  • This field is for validation purposes and should be left unchanged.

Not recently active