How To Create Admin Credentials by Command in Magento 2.x

There are following below command need to run ro create Admin username & Password

php bin/magento admin:user:create --admin-user=demo --admin-password=demo123$% --admin-email=johndusa@gmail.com --admin-firstname=John --admin-lastname=Donald

Note:: Your password must include both numeric and alphabetic characters

If not included password as both numeric and alphabetic characters Error as below

“It shows an error: Your password must include both numeric and alphabetic characters. The password should be more complex.”

once successfully command run, created a new admin account. The system returns this message:

Created Magento administrator user named demo

Each part of CLI command explained here as below

admin-user=demo [Admin User Name]

admin-password=demo123$% [ Admin Password ]

admin-email=johndusa@gmail.com [ [ Admin Email ]

admin-firstname=John

admin-lastname=Donald

2 thoughts on “How To Create Admin Credentials by Command in Magento 2.x

  1. It’s a pity you don’t have a donate button! I’d certainly donate to this excellent blog! I guess for now i’ll settle for book-marking and adding your RSS feed to my Google account. I look forward to brand new updates and will share this site with my Facebook group. Chat soon!

Leave a Reply

Your email address will not be published. Required fields are marked *