Home > Tech > Coding > How To Change php.ini Settings on Godaddy

How To Change php.ini Settings on Godaddy

How many times have you had to change your PHP settings and couldn’t figure out how to do it on your hosting service? If you are using Godaddy with cPanel, I’ll show you how.

If you search Godaddy’s help documentation, it says to modify a .user.ini file (see below) but I didn’t find one so that’s apparently not the way to do it.

Instead, just modify the .htaccess file as shown below and upload it to your website via FTP:

php_value max_file_uploads 1000
php_value max_input_vars 3000

Notice it is not the same as what you would enter into php.ini. Normally, you would use:

max_file_uploads = 1000
max_input_vars = 3000

But notice each line starts with php value and does not contain any equal signs. To make sure the changes worked, just create a phpinfo.php file containing:

<?php phpinfo(); ?>

When you execute this PHP file, you will see all the current settings as shown below:


As you can see, max_input_vars has been changed to 3000 from the default 1000 value.

Hope this helps somebody because it took me a minute to figure it out.