உள்ளடக்கத்திற்கு செல்க
Sri Lanka · Colombo · GlobalMon–Fri, 09:00–18:00 IST

Magento 2 add a user via command line cli

Create Magento 2 admin users using command line. Quick CLI commands for adding users, setting roles, and managing administrator access.

Amila Rajapaksha
Written by
Amila Rajapaksha
CEO / Managing Director, Mobiz International (Pvt) Ltd

Amila Rajapaksha is the CEO and Managing Director of Mobiz International (Pvt) Ltd, a web design and development company based in Gampaha, Sri Lanka. Since 2010 he has helped businesses across Sri Lanka and overseas launch fast, search-friendly websites and online stores — working hands-on with WordPress, Magento and custom Laravel builds, and the SEO that makes them rank.

47 views 265 articles
Share:
Magento does not allow resetting password of an existing user using the command prompt CLI. But it allows creating new admin users via CLI. Login to the command line and change directory to your magento 2 root directory.
e.g. cd  /var/www/magento2
Enter the below command and press enter.
php bin/magento admin:user:create
The CLI will prompt for username, password, email address, first name and last name for the user being created.
Share:

Related Articles

Comments (0)

Log in or sign up to leave a comment.

No comments yet. Be the first to share your thoughts!