Recovering the Magento administrator password

Magento is the only one of the big platforms in the installer where there is no button to change the administrator password from cPanel. Joomla, Drupal, PrestaShop, OpenCart, Moodle and Flarum all have one; Magento does not. That is why this article exists: the routes are different.

First make sure you are at the right address. The Magento panel does not live at /admin: it lives in whichever directory was chosen when the shop was installed. If you do not know which, read the last section of this article before trying to recover any password.

1. From Magento itself

1 Open the panel address and click Forgot your password?
2 Enter the e-mail address of your administrator account. Magento sends a link to set a new one.
3 The link expires. If you are slow getting to your inbox, request another.
4 Nothing arrives? It is nearly always the shop being unable to send mail. See why your e-mail is not sending, check the junk folder, and move to route 2.

2. Create a new administrator from the command line

Magento ships with a command line tool that creates administration users. It is the clean route: it leaves the old password alone and simply gives you a new account to get in with.

1 Check that your account has SSH access. Some accounts have a shell and some do not: if yours does not, skip to route 3 or https://www.meu.mozout.co.mz/submitticket.php.
2 Connect over SSH and change into the directory where the shop is installed.
3 Run the Magento administration tool to create a user, giving first name, surname, e-mail, username and password. Use the full path to the PHP version you chose for the site: the default php on the command line may be a different one, and the tool refuses to run on a version the shop does not support.
4 Sign in with the new user and, from inside, deal with the old account: change its password or disable it.
Always keep two administrators, on different e-mail addresses. It is the cheapest way never to need this article again.

3. Ask us

If you have no SSH and the shop cannot send mail, https://www.meu.mozout.co.mz/submitticket.php. Tell us the domain, the directory where Magento lives and the e-mail address you want as administrator. We will create the user for you.

Do not try to change the Magento password by hand in phpMyAdmin. Unlike other platforms, Magento stores it in a format of its own, with a random part and an algorithm version number. Writing a plain value there will not let you in, and leaves the account with no valid password at all. If you have already done it, tell us.

Finding the panel address

If the problem is not the password but not knowing where the door is:

1 The Softaculous installations list in cPanel shows the administration address on your shop row. That is the quickest route.
2 The shop configuration file, at app/etc/env.php, holds an entry with the admin directory name. Open it in cPanel File Manager.
3 With that name, the address is the shop address followed by that directory.

To install from scratch, see installing Magento. For every other platform the cPanel button solves it: see installing a ready-made platform.

Locked out of the panel and without SSH? Send us the domain and the directory, and we will create a new administrator for you.

Open a support ticket

SEE ALSO

Password generator

Support Policy

Frequently asked questions

RECOMMENDED PRODUCT

Web hosting with cPanel

Domain and SSL included, daily backups and the panel you already know. from $10.00/mo

See plans
  • 0 Users Found This Useful
Was this answer helpful?