[Solved] phpmyadmin Failed to set session cookie. Maybe you are using HTTP instead of HTTPS

I install PHP, Apache, and MySQL done and worked.
When I finish installing Phpmyadmin, then open it has an error.

Failed to set session cookie. Maybe you are using HTTP instead of HTTPS.

I don’t know why.
How can I fix this?

Enquirer: Lancer


Solution #1:

After searching the net for a solution to this problem i figured out that in my case a specific chrome extension caused the login problem.
So i recommend to disable your extensions .

In my case the chrome extension that caused the problem was called : Safe torrent scanner

Respondent: HenryW

Solution #2:

Just had this issue on Chrome today, the following worked for me so I thought I’d share it.

Navigate to the Inspector > Application > Clear Storage > Go ahead and clear everything.

enter image description here

Respondent: Elliot

Solution #3:

I had the same problem and a quick workaround was to use Incognito mode

Respondent: user972616

Solution #4:

I had this issue today, and here are the steps that I did that helped me fix it on Chrome:

enter image description here

1- Right click anywhere on the page, and choose “inspect” or click F12 to open developer tools.

2- From the top menu, choose “Application”.

3- Click Cookies on the left menu.

4- You will find some cookies there, click each one, and click “X” on the top to remove it. After removing all of them, refresh the page.

Respondent: Ibrahim

Solution #5:

You don’t seem to be the first to experience this; there’s one other before you:

I’ve personally had trouble where I have to press the button to log in a second time, but it works for me. The person who opened that bug was completely unable to log in.

So basically it’s currently an open and known bug and hopefully it will be fixed for the next phpMyAdmin release.

Respondent: Isaac Bennetch

Solution #6:

I have had this issue in the past however was successful in solving it using the instructions provided in this answer. (using phpMyAdmin version

Navigate to

in your server files and examine the following section:

/* Authentication type and info */
$cfg['Servers'][$i]['auth_type'] = 'cookie';
$cfg['Servers'][$i]['user'] = 'username';
$cfg['Servers'][$i]['password'] = 'password';
$cfg['Servers'][$i]['extension'] = 'mysqli';
$cfg['Servers'][$i]['AllowNoPassword'] = true;

If not already performed, comment out the user and password lines and makes sure the auth_type is set to cookie.

From my experience, this action needs to take place for phpMyAdmin to operate with cookie authentication before you move on.

Next perform the following steps to solve the session cookie not working with HTTP:

  1. Enter your browser settings (e.g. for Google Chrome go to chrome://settings/)
  2. Attempt to locate the setting to clear cookies, cached data, images and files, history, etc.
  3. After you successfully find this, clear your browser’s browsing history, download history, cached images and files, and content settings.
  4. Clear the cookies for the phpMyAdmin login page.
    Note: In Internet Explorer, it is slightly difficult to view and delete the cookies. An internet article is available from Ask Leo about viewing cookies in IE if you need help.

I received the idea of performing the above instructions because I eyed someone at this GitHub issue mentioning private mode. This is a comment from nik6018:

As stated in #14234 Login via HTTP works if in private mode, but doesn’t work in normal session.
I tried to clear the cookie for the domain but still the same issue.

Private mode reminded me of issues I have had in the distant past like this one, and I remember having to clear various browser items.

On account of my reminder from the distant past, I tried the above instructions in a different sequence or way than I presented them, and it worked.

Respondent: Ewer Ling

Solution #7:

Well, it’s one of two things. Either you don’t have TLS/HTTPS enabled on your production box (which you definitely should! — good resources for getting started are Let’s Encrypt and whatever host you’re using) OR
you’re probably trying to access a development server in a production mode. In the latter case, while I’m not familiar with PHPMyAdmin myself I’d guess there’s a configuration file somewhere that dictates when it should act like a production server versus a local server and you can just toggle that. But definitely don’t toggle your production server to act like a development server, then you’re just giving up security for convenience which will eventually come back to bite you.

Respondent: Venantius

Solution #8:

I had the same problem, but, in my case, the problem was my VPN, so I disabled it.

If you are using a VPN you need to disable it
or just disable you cookie blocking.

enter image description here

Respondent: tp45

Solution #9:

The issue should be solved using phpMyAdmin 4.9.2 as I made a fix for it but if you still have the issue please comment on

phpMyAdmin team

Respondent: William Desportes

Solution #10:

I found one reason for this error


If your browser has a Secure cookie and you are browsing a non secure connexion, the non secure connexion will send a new non secure cookie.
And the browser will refuse to overwrite the Secure one.
Leading to an endless loop.

“Failed to set session cookie. Maybe you are using HTTP instead of HTTPS to access phpMyAdmin.”

I also tried “Privacy Badger” but could not reproduce the issue.

Respondent: William Desportes

Solution #11:

I faced this issue on phpMyAdmin-4.9.1. I simply renamed config file from to

Respondent: Jimit Shah

Solution #12:

Just clear the cookies and the cache in your browser. This is how it worked for me.

Respondent: Ivan Ivanov

Solution #13:

I just ran into this problem using Firefox 61 on a site I had been using regularly, so I knew my config settings were correct. In fact, I could go in using Private Mode. So, in non-private mode, using the Firefox Developers Tools, I cleared ALL Session cookies and VOILA. Worked perfectly.

Respondent: DBStamps

Solution #14:

My solution was to disable (add an exception for my domain) to the “Privacy Badger” Firefox Extension.

As soon as I did this, I was able to log in.

The other solutions in this post (config.ini.php, browser cache, VPN) did not do anything for me. Seems like the issue is primarily tied to environment / browser config, which could be unique for each person.

I don’t think it’s an issue with PHPMyAdmin.

Respondent: Frantumn

Solution #15:

Region is Chrome Extension. if you do not want change any thing then open url in other browser (Like Safari or Mozila) its working fine.

Respondent: Nanhe Kumar

Solution #16:

I had this issue because I am hosting phpmyadmin behind an nginx reverse proxy, using Docker Compose. In my docker-compose.yml file I had:

    image: phpmyadmin/phpmyadmin:latest
    restart: always
      - PMA_HOST=http://db
      - PMA_PORT=3306
      - PMA_ABSOLUTE_URI=http://localhost/db-admin/  # necessary because the db-admin is hosted behind a reverse proxy.
      - 8084:80
      - db
      - shared-network

Due to the reverse-proxy and the PMA_ABSOLUTE_URI, I can only use this application on http://localhost/db-admin, not on http://localhost:8084.

The answers/resolutions are collected from stackoverflow, are licensed under cc by-sa 2.5 , cc by-sa 3.0 and cc by-sa 4.0 .

Most Popular

To Top
India and Pakistan’s steroid-soaked rhetoric over Kashmir will come back to haunt them both clenbuterol australia bossier man pleads guilty for leadership role in anabolic steriod distribution conspiracy