Magento Tutorials

Magento Admin Login Not Working Issue

Cannot login to your Magento backend?

Magento admin login not working: Although you have entered the correct username and password, you still cannot access your Magento backend. You are redirected to the same login page. Nothing happened. How to resolve this issue? Here are some tips which may help you.

The reason might be that you’re accessing the Magento website through the hostname localhost. Magento checks whether the hostname is a real domain name, and if it isn’t, it fails to create the right cookies.

  • Under Linux or MacOS you could try using localhost.localdomain.
  • Under Windows you have to modify your hosts file for this. Easier is just to use the IP-address to access Magento.

If the solution above doesn’t work, follow the steps below:

  1. Go to app/code/core/Mage/Core/Model/Session/Abstract/Varien.php file within your magento directory.
  2. Find the code:







and replace it into this one:







  1. Save the file. And try to login to your admin again.

See more:
Magento Maintenance Mode
Magento 2 “Invalid Form Key”

A knowledge craver who always strive to be wiser everyday.

Notify of