Increase GoDaddy max_execution_time

·

I recently moved a couple of my sites from Dreamhost to GoDaddy’s managed WordPress hosting.

While one of the websites migrated perfectly fine, the other website had issues with the WordPress importer failing. :/

My best guess of what was happening is that the GoDaddy max_execution_time was set quite low, which was causing the importer to fail. I confirmed this by downloading the phpinfo plugin which showed the following:

GoDaddy max_execution_time before

Let’s Increase the GoDaddy max_execution_time

It took a bit for me to figure out how to increase the max_execution on GoDaddy’s managed WordPress hosting, but after quite a bit of search I found an article on GoDaddy’s support portal that describes where to put the PHP initialization files for the varying GoDaddy hosting products.

Easily enough, the PHP initialization file for GoDaddy’s managed WordPress hosting is located at html, which is the initial directory upon logging in to SFTP.

So, to increase GoDaddy max_execution_time, all I had to do was:

  • Open an SFTP connection
  • In the same directory as wp-config.php, create a .user.ini file. Note the leading .
  • Lastly, in this .user.ini file, I added the following:

[code lang=text]
max_execution_time = 180
[/code]

The above will increase the GoDaddy max_execution_time to 3 minutes, which you can verify yourself by using the phpinfo plugin mentioned above.

GoDaddy ini After

Unfortunately for me, increasing the GoDaddy max_execution_time didn’t fix my issue of the WordPress importer failing. I ended up moving my site to WP Engine which worked like a charm.

Comments

30 responses to “Increase GoDaddy max_execution_time”

  1. Luke Avatar

    You are a LIFE SAVER!! I went through so many other hoops trying to change this setting on my godaddy wordpress site…editing php.ini and php5.ini and htaccess files and nothing worked….until i found this!! Thank you for sharing!!!

  2. Sarah Avatar

    I tried doing this, but upon verification, max_execution_time is still at 180. (I need it at 600). I did, changed it to 600 though. But still the same.

    Named the file .user.ini

    Is there anything that I am doing wrong?

    1. Eric Binnion Avatar

      Hi Sarah,

      My apologies for the slow reply. I had several issues with GoDaddy managed and eventually moved my sites elsewhere.

      One thing I’ll mention though is that the name of the ini file changes depending on what GoDaddy product you are using. So, for the GoDaddy managed WordPress product, the file is named .user.ini. But, other products expect different filenames, which is described in this article.

  3. Gary David Avatar

    Thanks a ton!

    I was chatting with godaddy support and they told me to just type in the number and not the whole “max_execution_time = xxx”.

    1. Eric Binnion Avatar

      My apologies for the slow reply. Thanks for leaving a comment after talking with support! Hopefully others find it helpful. ?

  4. Yamen Shahin Avatar

    You are awesome! I never know this about GoDaddy.I think we can also change some other parameter as well here like max_input_vars = 2000 and so on

  5. Michael Avatar

    Great help. I was also able to change upload_max_filesize in the .user.ini file. Just remember to put an “M” at the end or you’ll get an error (i.e. upload_max_filesize = 40M).

  6. Kris Bey Avatar

    Fantastic! Thank you, i don’t usually use GoDaddy but occasionally a client is self hosted and you have to fix theses hosting issues. This was right on the money!

  7. daniyalahmedk Avatar

    Thank you so much!!! i have spent hours for making this fix. tried httacess nothing works. But your solution .user.ini works for me!!

  8. baidyanath Avatar
    baidyanath

    I uploaded the file and the new max_execution_time is updated as local value, may be it is due to the domain is added as addon domain. The master max_execution_time is 30.

  9. Alexander Avatar
    Alexander

    Thank you for this post. .user.ini file is the ticked for godaddy’s horrendous server default limitations and no where on their support forums do they show this tutorial.

    max_execution_time = 300
    max_input_vars = 2000

    Cheers!

  10. THANKS Avatar

    after a couple hours trying to resolve this problem while nothing else worked, i came across this post and it worked. thanks!

  11. Bob Avatar

    I Really Needed To Say Thank You!…
    I Need To Bulk Add Tags To My WordPress Posts So That In-Turn I Could Use Tags In A MegaMenu.
    Bulk Editing And Adding Tags Timed Me Out… You Solved This Problem In 3 Mins!
    Thank You

  12. Ashique Avatar

    Yes it is working, but you do not need to open SFTP connection,
    You can create file .user.ini with normally it will work.

    1. Eric Binnion Avatar

      I recommended opening an SFTP connection because I used Transmit (an FTP program) to create and edit the .user.ini file.

      If GoDaddy has a file viewer or SSH access, I suppose you could do it that way though.

  13. Jake Avatar

    RE: Max Execution Time with WP Engine,

    I was just told by them: “We have a server-side script that kills processes at 60 seconds so unlimited will not technically be possible.
    We are not be able to disable or alter this kill script, as this is programmed at the root of our platform and is in place to protect the entirety of our shared platform and services.”

    So altering the ‘max_execution_time’ won’t matter or resolve the issue I am having due to their server-side 60 second kill script

  14. Shakeera Avatar

    Thank you brother.. It is working, but we do not need to open SFTP connection,
    You can create file .user.ini with normally it is working.

  15. inlovearoundtheworld2017 Avatar
    inlovearoundtheworld2017

    I am not a web developer or programmer but managed to get it done, thanks to you! You are a life saver! Thanks so much!

  16. David Walker Avatar

    Hi Eric
    You can now also change those settings in the godaddy account
    Go to
    PHP Version in your settings and then
    “Switch To PHP Options”
    Not that i would recommend Godaddy either, but just in case someone needs it

    1. Kunal Sarin Avatar

      David, you made it simpler than ever.

      For those who are looking for a little more elaborated setps,

      Go into cPannel, scroll down until you see “Software” section.
      Click “Select PHP version”
      On this page, you should see a button on the right as “Switch to PHP Options”
      Viola! you can changes these settings there.

  17. Thea Avatar

    Thank you for your instructions, but, phpinfo plugin isn’t compatible with my current version of wordpress.

    Suggestions welcomed..
    Did anyone use a different plugin that was successful.

    Thanks

Leave a Reply to BobCancel reply

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

Discover more from Eric Binnion

Subscribe now to keep reading and get access to the full archive.

Continue reading

Discover more from Eric Binnion

Subscribe now to keep reading and get access to the full archive.

Continue reading