Change WordPress upload file size

Create a file called junk.php with the following content.

phpinfo() ;

Place junk.php in your WordPress root directory.

In your browser of choice enter:

This will output a lot if data if your php environment is functioning properly. Look for the following:

php.ini – the path to your php.ini file will be here.
upload_max_filesize 2M

vi your php.ini file (noted in the above output) looking for “upload_max_filesize” and change it to what you think you need, i.e., 33M. Restart apache (sudo service apache2 restart) to pick up the new value. Look at “” (may need to force a refresh) to see your new “upload_max_filesize” value. This should correct your 2M limitation.

I have seen a lot of posts where many have changed this value in their php.ini file and “nothing happens”. I am assuming that this is because the apache server (or whatever they are using) is not being restarted to acquire these new values.

Hope this helps.

4 Responses to Change WordPress upload file size

  1. Billye says:

    EXTREMELY HELPFUL!!! Thank you sooooo much!

  2. Hayden Bennett says:

    WordPress is the best blogging platform ever. It is much better than Typepad and blogspot.~.:

  3. Harley Marshall says:

    i host 5 of my blogs on Blogspot and it is really good for beginners. but if you want something with more features, nothing beats wordpress;`’

  4. Gal says:

    I can’t believe your tip still being so helpful for so many years after digging on the Net for few hours without much help… since too many different possibilities on how php reads the php.ini in many ways. I run my own Apache server @ home and at first this problem was taken care by placing the php.ini in the same folder as php binary located (ie /usr/local/bin) but somehow for some unknown reasons it didn’t take effect anymore…

    Anyway, great info! Thanks so much!

Leave a Reply

Your email address will not be published. Required fields are marked *


This site uses Akismet to reduce spam. Learn how your comment data is processed.