Your Dedicated Partner for All Things WordPress

How to Increase Your File Upload Size in WordPress

Table of Contents

Are you running into issues with file upload size limits when using WordPress? If so, you’re not alone. By default, WordPress has a maximum file upload size of 2MB which can be difficult to work with if you’re dealing with large media files. In this blog post, we’ll discuss how to increase the maximum file upload size in WordPress.

There are several ways to increase the maximum file upload limit in WordPress. The two most common approaches involve either editing your .htaccess file or adding code snippets to your functions.php theme file. Let’s take a closer look at both methods and why they work.

Urgent WordPress Assistance

Facing a critical WordPress issue? Don’t panic. Our Emergency Service is here to swiftly resolve any urgent website problems.

Editing .htaccess File Method: For this method, you will need to add the following code snippet directly into your .htaccess file found inside the public_html directory of your site:

php_value upload_max_filesize 64M         php_value post_max_size 64M           php_value max_execution_time 300         php_value max_input_time 300

This code will increase the maximum file upload size from 2MB to 64MB and also increase other parameters like post max size, max execution time and max input time which can also affect the overall size of a file you can upload on your website. It is important to note that if you have access to cPanel or any other control panel provided by your hosting provider then it is better than manually editing .htaccess file as an incorrect code could crash your website.

Functions.php Method: If you don’t have access to cPanel or any other control panel then here is another way for increasing the maximum file upload size in WordPress by adding a few lines of code into your functions.php theme file located in wp-content/themes folder within WordPress installation directory:


Increasing the maximum allowed file upload size on a WordPress site can be done by either editing .htaccess or adding code snippets into functions.php theme files – whichever method works best for you depends on whether or not you have access to cPanel or any other control panel provided by hosting provider as well as the type of files that needs uploading on website (if they are large). We hope this blog post has been helpful in teaching how to increase your file upload size in WordPress! Have questions? Feel free to reach out and contact us for more information about increasing the maximum allowed filesizeb for uploading media on your website! 🙂

Tailored WordPress Solutions

Elevate your online presence with our custom WordPress development services.

How to get started?

Learn more

WordPress Maintenance

Save 33% with our Annual pricing plan.

Get Started

Coupon Code Applied!

Take your time and continue browsing our services.

Alexey Seryapin
Founder of WPServices