Reset admin password in prestashop
Blogs April 28th, 2009
If you’re like me and you tried the “lost password” link on prestashop’s backend and never received the email, you might try this solution if you have access to the database. Look in config/settings.inc.php for the _COOKIE_KEY_ as you’ll need that. Run the following SQL and replace the <> variables with your information.
UPDATE employee SET passwd = md5(”<_COOKIE_KEY_><yourNewPassword>”) WHERE email = “youremailaddress”;
hope that helps
credit: nickbartlett.com
About
thank you very much. ขอบคุณมากๆครับ
I have problem when I upload prestashop from localhost to web hosting. Thank for solving my problem
Thank you, Nick. Simple solution.
One note, there is no space between and . Be sure to enter it *precisely* as Nick’s instructions specify.
Don’t ask me how I know this!

Worked great.
Well, in my previous post, the site thought I was entering HTML in this comment field. This time I won’t use angle brackets.
I was talking about the _COOKIE_KEY_ value and the yourNewPassword value. Don’t add a space between the two.
@drub
Yes, there is no space between _COOKIE_KEY_ and yourNewPassword. For example,
UPDATE employee SET passwd = md5(”VRKEZbXzP7Uo5nV1CJTPnwJjvIX7knoRD1b884IB11pMnHobfuNShnMWMyNewPassword”) WHERE email = “myemail@example.com”;
Note: VRKEZbXzP7Uo5nV1CJTPnwJjvIX7knoRD1b884IB11pMnHobfuNShnMW is the value of _COOKIE_KEY_
Hello
I want to install a prestahop site from my local computer to de host and i have the same problem.
I have tried regenerate the password like you explain
but with this technique i can’t log with te admin user.
Please help
Thank in advance
@teosanchez
Firstly, checking employee table in your database, see whether the email is the same as your command.
If email is matched, passwd column should be changed as per your command.
@teosanchez Not sure if you ever got this to work or not, it had originally failed for me too. I’m can’t remember what the limitations for the password are in Prestashop, but I had a ’special character’ in mine and the script didn’t work. Once I removed it (kept to [a-z0-9] and re-ran the example from the post, it worked fine.
i am using prestasop 1.1.0.5 which uses mysql 5; I do things like
UPDATE employee SET passwd = md5(’5FoJoH7nzcojFLibXgCEubxWcwANa3CEAVecYImy3nFC0NOU5QMG3pvn’) WHERE email = ‘youremail@hotmale.com’;
it depends on your mysql server, please read your mysql server manual
many thanks, you saved my live THANKS
i have installed prestashop.
i import database from other website.
the admin login is not working.
i change the password using the mentiond command but still not working.
UPDATE ps_employee SET passwd = md5(”VRKEZbXzP7Uo5nV1CJTPnwJjvIX7knoRD1b884IB11pMnHobfuNShnMWMy123456”) WHERE email = “waqar.pk2108@gmail.com”;
i set the password 123456 but not working.
tell me the problem
This is a response to johny’s post
You should try to set the password length to 8 characteres or longer because prestashop has a restriction on this.
Maybe you can try it to window echo or print forexample print $pwd;
Your way to help me solve the problem, thank you
Thanks man, you save me a lot of time…
Hi
I used
UPDATE employee SET passwd = md5(’FPYLIg5KJ1b94m2dayvVcubWZbVe5OEq4nwnJI2xj8g3nAW1GC1y5KTwMyPassword’) WHERE email = ‘nigel@example.co.uk’;
and it worked fine. Need single quotes and ps_employee for the table.
thanks for the ifo!!
Nigel
Hi all, played around for ages the other night and for me this worked.
UPDATE `YourMySqlDatabaseName`.`ps_employee` SET `passwd` = MD5(’HereYourCookieKeyAndPasswordWithNoSpaces’) WHERE `ps_employee`.`id_employee` = 1;
Simple way.
1. Create a new customer
2. Copy the customer password to your admin password field
3. Done
UPDATE theproxymaker.ps_employee SET `passwd` = MD5(”rRcaSOfYPiFd1i3OwZRyPExZucGpoDBYQjWsNzHVOqKP0tvqWBRo7BHVsuppaman123″) WHERE `ps_employee`.`id_employee` = 1;
in this my it works