WordPress is an open source content management tool. It is written in PHP and MySQL. It is an easy platform to create beautiful sites. WordPress uses different plugins, themes, and media files to organize the website. With WordPress, it is easy to create simple blogging sites to full-fledged website. During the course of website development in WordPress, you will face an issue where you won’t be able to upload large file size. In this guide, we will focus on how we can fix this issue easily by editing some minor PHP functions.
- A Domain Name (e.g., test.com)
- Hosting service with cPanel Access
Step 1: cPanel Login
Go to cPanel admin URL and enter your Credentials to enter the control panel of your hosting.
Click on File Manager to access the root directory of your WordPress site.
Now, we need to access the php.ini file using the file manager app or by using an FTP program if you are using a shared host. You can create a php.ini file yourself and add to the root folder of the site if you don’t find one.
We need to edit some code after opening the php.ini file. The three codes we need to edit are post_max_size, upload_max_filesize, and memory_limit. Search for these keywords in the php.ini file.
We have changed all the value to 300 M for post_max_size, upload_max_filesize and memory_limit.
Depending upon on the server setup, we can also change the limit from the UI. For that, go to your cPanel and look for Select PHP version from the UI.
Click on Switch to PHP option and then you can change the upload_max_filesize from a set of options.
By following the above steps, you can increase the maximum file size upload in WordPress and install different plugins and media files to your sites.
Check out these top 3 WordPress hosting services: