Fix PHP Uploaded File Exceeds upload_max_filesize – XAMPP

There are quite a number of PHP local development server such as WAMP, EasyPHP and XAMPP but i prefer using the latter. I was building a WordPress blog on xampp, while trying to install a theme, i got this error:

The uploaded file exceeds the upload_max_filesize directive in php.ini.

From the error message, I knew I need to increase the maximum file size value in php.ini file. By default, the upload_max_filesize is set to 2MB in XAMPP, maybe also in WAMP and EasyPHP.

To resolve this problem, first we need to locate where the php.ini file is. in Xampp, it is found in C:\xampp\php. Open the php.ini file, search for “upload_max_filesize” and replace the “2M” (meaning 2-Megabyte) to a higher value, say “50M”.

upload_max_filesize php.ini code

Afterward, restart Apache for the change to take effect.

Don’t miss out!
Subscribe to My Newsletter
Invalid email address