No activity within 1800 seconds; please log in again

1800 seconds is such a long time, right?

  1. It’s 30 minutes.
  2. It’s 0.5 hours.
  3. It’s 0.0208333333 days.
  4. It’s also 5.70397764 × 10-5 years.

And it’s not long enough for me. phpMyAdmin logs you out after 1800 seconds, obviously for security reasons. That’s fine if there are other people about, if I was in an office with people coming and going, but I work from home. All I see for most of the day is my family, the radio, my messy desk, computers, and the view out the window. Time to figure out how to make that 1800 second limit a little longer or remove it altogether.

After a little digging, I discovered that extending the time limit to a day is actually quite easy. Open your phpMyAdmin’s and search for or add the following line:

$cfg['LoginCookieValidity'] = 86400;

Refresh your logged out phpMyAdmin and presuming you haven’t left it idle for 24 hours, you’ll be logged in again!

If the time limit really bugs you, you need http authentication. Look for the “auth_type” line in the and change that to “http”. phpMyAdmin won’t log you out as long as your browser is open. Perfect!

If you’re concerned about sending your MySQL username and password in the clear each time you make a request to phpMyAdmin you can either use SSL or try the “config” auth_type. Make sure you fill in the username and password fields in the config file, and secure the phpMyAdmin directory with a htpasswd file.

23 thoughts on “No activity within 1800 seconds; please log in again

  1. I changed the file as laid out above, but it still logs me out when I least expect it. The only difference it made was that it no longer gives the reason as being that I was inactive for 1800 seconds. It gives no reason at all. There must be some other setting somewhere that also sets a time limit.

  2. Fantastic, I was finding that I was thrown off after just a few seconds, this mod fixed that for me. Thanks.

  3. Great tip, but it seems to be working only on some systems. On my Linux machine it seems to be working, but on my Windows Server 2003 it is not working.

  4. Sorry, it is working anyway also on Windows Server 2003, I had been adjusting the time settings to 1 year ahead because I was testing some other script. Of course, phpMyAdmin throws me off.
    Stooopid me!! Thanks for the tip once again!

  5. I found you need to clear the relevant cookies too, and make sure you go to the site fresh (without any ?token=B6D5BC… junk on the end)

  6. Thanks so much, I swear it feels like I have logged in over a hundred times today, nothing more annoying than practicing your password typing skills every 30 minutes to reference table structures.

  7. clear your browser cache including cookies and you will find that you are not hampered with this problem and don’t have to make modifications to your config file

  8. hello Jake. I also use XAMPP, so to change this you must do it in two places:


    change LoginCookieValidity from 1440 to …let say … 86400

    and do the same at


    with session.gc_maxlifetime variable … as Dallas said

  9. Found this error while browsing databases on GoDaddy. I had not been inactive for more than a few seconds. It may be a generic ‘catch all’ / “we’d rather not tell you what the problem is” error message. Be aware that management are always keen to subvert error messages such that their organization doesn’t look so bad when they occur, at the absolute pain of the end user who gets bogus diagnostics instead of anything remotely useful.

Leave a Reply

%d bloggers like this:

By continuing to use the site, you agree to the use of cookies. more information

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.