Skip to main content

Command Palette

Search for a command to run...

Magento 2  -  Update Customer/Admin Password via Query

Published
1 min read
F

I wrote these tutorials for myself in future when I forget for the next steps.

Update password can be done via mysql query, simply just execute this query to update customer’s password :

UPDATE customer_entity SET password_hash = CONCAT(SHA2('xxxxxxxTypeYourPasswordHere', 256), ':xxxxxxx:1') WHERE email = 'johndoe@example.com';

And this query for admin :

UPDATE admin_user SET password = CONCAT(SHA2('xxxxxxxTypeYourPasswordHere', 256), ':xxxxxxx:1') WHERE email = 'johndoe@example.com';

Notes :

  • Change TypeYourPasswordHere by new password **without **removing xxxxxxx

  • Change **johndoe@example.com **by email of customer/admin.

More from this blog

F

Fiko Borizqy (Bestafiko)

51 posts

I wrote these tutorials for myself in future when I forget for the next steps.

Magento 2  -  Update Customer/Admin Password via Query