{"id":112192,"date":"2018-02-13T08:35:58","date_gmt":"2018-02-13T08:35:58","guid":{"rendered":"https:\/\/webkul.com\/blog\/?p=112192"},"modified":"2024-02-22T13:13:04","modified_gmt":"2024-02-22T13:13:04","slug":"create-edit-magento-2-admin-user-account-via-cli","status":"publish","type":"post","link":"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/","title":{"rendered":"Create\/Edit Magento 2 Admin User Account via CLI"},"content":{"rendered":"\n<p>You can create or edit a Magento 2 admin user account using the command line.<\/p>\n\n\n\n<p>For that, you have to open the terminal\/command prompt.<\/p>\n\n\n\n<p>After that go to your Magento site\u2019s root directory in the terminal, for example, your Magento site can be in a folder\/directory path as \/var\/www\/html.<br>So go to that directory from the command line and after that execute the below command.<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\">php bin\/magento admin:user:create --admin-user=&#039;new-user&#039; --admin-password=&#039;admin123&#039; --admin-email=&#039;admin@admin.com&#039; --admin-firstname=&#039;Admin&#039; --admin-lastname=&#039;Admin&#039;<\/pre>\n\n\n\n<p>Once the Magento 2 admin user account is created then you will see the below success message.<\/p>\n\n\n\n<figure class=\"wp-block-image\"><img decoding=\"async\" width=\"474\" height=\"60\" src=\"https:\/\/cdnblog.webkul.com\/blog\/wp-content\/uploads\/2018\/02\/Screenshot_2-2.png\" alt=\"Screenshot\" class=\"wp-image-112208\" srcset=\"https:\/\/cdnblog.webkul.com\/blog\/wp-content\/uploads\/2018\/02\/Screenshot_2-2.png 474w, https:\/\/cdnblog.webkul.com\/blog\/wp-content\/uploads\/2018\/02\/Screenshot_2-2-250x32.png 250w, https:\/\/cdnblog.webkul.com\/blog\/wp-content\/uploads\/2018\/02\/Screenshot_2-2-300x38.png 300w\" sizes=\"(max-width: 474px) 100vw, 474px\" loading=\"lazy\" \/><\/figure>\n\n\n\n<p><strong>&#8211;admin-user-&gt;<\/strong>&nbsp;Admin account username (<strong>required<\/strong>).<br><strong>&#8211;admin-password-&gt;<\/strong>&nbsp;Admin User account password (<strong>required<\/strong>).<br><strong>&#8211;admin-email-&gt;<\/strong> Admin user account&#8217;s email address (<strong>required<\/strong>).<br><strong>&#8211;admin-firstname-&gt;&nbsp;<\/strong>Admin user&#8217;s first name (<strong>required<\/strong>).<br><strong>&#8211;admin-lastname-&gt; <\/strong>Admin user&#8217;s last name (<strong>required<\/strong>).<\/p>\n\n\n\n<p><strong>Note:&nbsp;<\/strong>If you are editing an existing user then&nbsp;only the first name, last name, and password can be edited.<\/p>\n\n\n\n<p>Hope it will help you. Thank you.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>You can create or edit a Magento 2 admin user account using the command line. For that, you have to open the terminal\/command prompt. After that go to your Magento site\u2019s root directory in the terminal, for example, your Magento site can be in a folder\/directory path as \/var\/www\/html.So go to that directory from the <a href=\"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/\">[&#8230;]<\/a><\/p>\n","protected":false},"author":171,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[302],"tags":[2460,6170],"class_list":["post-112192","post","type-post","status-publish","format-standard","hentry","category-magento2","tag-magento-2","tag-magento-2-command-line"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v24.5 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Create\/Edit Magento 2 Admin User Account via CLI - Webkul Blog<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Create\/Edit Magento 2 Admin User Account via CLI - Webkul Blog\" \/>\n<meta property=\"og:description\" content=\"You can create or edit a Magento 2 admin user account using the command line. For that, you have to open the terminal\/command prompt. After that go to your Magento site\u2019s root directory in the terminal, for example, your Magento site can be in a folder\/directory path as \/var\/www\/html.So go to that directory from the [...]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/\" \/>\n<meta property=\"og:site_name\" content=\"Webkul Blog\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/webkul\/\" \/>\n<meta property=\"article:published_time\" content=\"2018-02-13T08:35:58+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-02-22T13:13:04+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/webkul.com\/blog\/wp-content\/uploads\/2018\/02\/Screenshot_2-2.png\" \/>\n<meta name=\"author\" content=\"Anuj Gupta\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@webkul\" \/>\n<meta name=\"twitter:site\" content=\"@webkul\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Anuj Gupta\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"1 minute\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/\"},\"author\":{\"name\":\"Anuj Gupta\",\"@id\":\"https:\/\/webkul.com\/blog\/#\/schema\/person\/8b6a9038345794233c3cf41b15a330c4\"},\"headline\":\"Create\/Edit Magento 2 Admin User Account via CLI\",\"datePublished\":\"2018-02-13T08:35:58+00:00\",\"dateModified\":\"2024-02-22T13:13:04+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/\"},\"wordCount\":160,\"commentCount\":4,\"publisher\":{\"@id\":\"https:\/\/webkul.com\/blog\/#organization\"},\"image\":{\"@id\":\"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/webkul.com\/blog\/wp-content\/uploads\/2018\/02\/Screenshot_2-2.png\",\"keywords\":[\"Magento 2\",\"Magento 2 Command Line\"],\"articleSection\":[\"Magento2\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/\",\"url\":\"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/\",\"name\":\"Create\/Edit Magento 2 Admin User Account via CLI - Webkul Blog\",\"isPartOf\":{\"@id\":\"https:\/\/webkul.com\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/webkul.com\/blog\/wp-content\/uploads\/2018\/02\/Screenshot_2-2.png\",\"datePublished\":\"2018-02-13T08:35:58+00:00\",\"dateModified\":\"2024-02-22T13:13:04+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/#primaryimage\",\"url\":\"https:\/\/cdnblog.webkul.com\/blog\/wp-content\/uploads\/2018\/02\/Screenshot_2-2.png\",\"contentUrl\":\"https:\/\/cdnblog.webkul.com\/blog\/wp-content\/uploads\/2018\/02\/Screenshot_2-2.png\",\"width\":474,\"height\":60},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/webkul.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Create\/Edit Magento 2 Admin User Account via CLI\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/webkul.com\/blog\/#website\",\"url\":\"https:\/\/webkul.com\/blog\/\",\"name\":\"Webkul Blog\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\/\/webkul.com\/blog\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/webkul.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/webkul.com\/blog\/#organization\",\"name\":\"WebKul Software Private Limited\",\"url\":\"https:\/\/webkul.com\/blog\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/webkul.com\/blog\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/cdnblog.webkul.com\/blog\/wp-content\/uploads\/2021\/08\/webkul-logo-accent-sq.png\",\"contentUrl\":\"https:\/\/cdnblog.webkul.com\/blog\/wp-content\/uploads\/2021\/08\/webkul-logo-accent-sq.png\",\"width\":380,\"height\":380,\"caption\":\"WebKul Software Private Limited\"},\"image\":{\"@id\":\"https:\/\/webkul.com\/blog\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/www.facebook.com\/webkul\/\",\"https:\/\/x.com\/webkul\",\"https:\/\/www.instagram.com\/webkul\/\",\"https:\/\/www.linkedin.com\/company\/webkul\",\"https:\/\/www.youtube.com\/user\/webkul\/\"]},{\"@type\":\"Person\",\"@id\":\"https:\/\/webkul.com\/blog\/#\/schema\/person\/8b6a9038345794233c3cf41b15a330c4\",\"name\":\"Anuj Gupta\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/webkul.com\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/a46d5e8da91ff0fecc16beee97bfb7b3a8ed158c64c69f50ddc3c1ce7d532e97?s=96&d=https%3A%2F%2Fcdnblog.webkul.com%2Fblog%2Fwp-content%2Fuploads%2F2019%2F10%2Fmike.png&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/a46d5e8da91ff0fecc16beee97bfb7b3a8ed158c64c69f50ddc3c1ce7d532e97?s=96&d=https%3A%2F%2Fcdnblog.webkul.com%2Fblog%2Fwp-content%2Fuploads%2F2019%2F10%2Fmike.png&r=g\",\"caption\":\"Anuj Gupta\"},\"url\":\"https:\/\/webkul.com\/blog\/author\/anuj-gupta701\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Create\/Edit Magento 2 Admin User Account via CLI - Webkul Blog","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/","og_locale":"en_US","og_type":"article","og_title":"Create\/Edit Magento 2 Admin User Account via CLI - Webkul Blog","og_description":"You can create or edit a Magento 2 admin user account using the command line. For that, you have to open the terminal\/command prompt. After that go to your Magento site\u2019s root directory in the terminal, for example, your Magento site can be in a folder\/directory path as \/var\/www\/html.So go to that directory from the [...]","og_url":"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/","og_site_name":"Webkul Blog","article_publisher":"https:\/\/www.facebook.com\/webkul\/","article_published_time":"2018-02-13T08:35:58+00:00","article_modified_time":"2024-02-22T13:13:04+00:00","og_image":[{"url":"https:\/\/webkul.com\/blog\/wp-content\/uploads\/2018\/02\/Screenshot_2-2.png","type":"","width":"","height":""}],"author":"Anuj Gupta","twitter_card":"summary_large_image","twitter_creator":"@webkul","twitter_site":"@webkul","twitter_misc":{"Written by":"Anuj Gupta","Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/#article","isPartOf":{"@id":"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/"},"author":{"name":"Anuj Gupta","@id":"https:\/\/webkul.com\/blog\/#\/schema\/person\/8b6a9038345794233c3cf41b15a330c4"},"headline":"Create\/Edit Magento 2 Admin User Account via CLI","datePublished":"2018-02-13T08:35:58+00:00","dateModified":"2024-02-22T13:13:04+00:00","mainEntityOfPage":{"@id":"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/"},"wordCount":160,"commentCount":4,"publisher":{"@id":"https:\/\/webkul.com\/blog\/#organization"},"image":{"@id":"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/#primaryimage"},"thumbnailUrl":"https:\/\/webkul.com\/blog\/wp-content\/uploads\/2018\/02\/Screenshot_2-2.png","keywords":["Magento 2","Magento 2 Command Line"],"articleSection":["Magento2"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/","url":"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/","name":"Create\/Edit Magento 2 Admin User Account via CLI - Webkul Blog","isPartOf":{"@id":"https:\/\/webkul.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/#primaryimage"},"image":{"@id":"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/#primaryimage"},"thumbnailUrl":"https:\/\/webkul.com\/blog\/wp-content\/uploads\/2018\/02\/Screenshot_2-2.png","datePublished":"2018-02-13T08:35:58+00:00","dateModified":"2024-02-22T13:13:04+00:00","breadcrumb":{"@id":"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/#primaryimage","url":"https:\/\/cdnblog.webkul.com\/blog\/wp-content\/uploads\/2018\/02\/Screenshot_2-2.png","contentUrl":"https:\/\/cdnblog.webkul.com\/blog\/wp-content\/uploads\/2018\/02\/Screenshot_2-2.png","width":474,"height":60},{"@type":"BreadcrumbList","@id":"https:\/\/webkul.com\/blog\/create-edit-magento-2-admin-user-account-via-cli\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/webkul.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Create\/Edit Magento 2 Admin User Account via CLI"}]},{"@type":"WebSite","@id":"https:\/\/webkul.com\/blog\/#website","url":"https:\/\/webkul.com\/blog\/","name":"Webkul Blog","description":"","publisher":{"@id":"https:\/\/webkul.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/webkul.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/webkul.com\/blog\/#organization","name":"WebKul Software Private Limited","url":"https:\/\/webkul.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/webkul.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/cdnblog.webkul.com\/blog\/wp-content\/uploads\/2021\/08\/webkul-logo-accent-sq.png","contentUrl":"https:\/\/cdnblog.webkul.com\/blog\/wp-content\/uploads\/2021\/08\/webkul-logo-accent-sq.png","width":380,"height":380,"caption":"WebKul Software Private Limited"},"image":{"@id":"https:\/\/webkul.com\/blog\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/webkul\/","https:\/\/x.com\/webkul","https:\/\/www.instagram.com\/webkul\/","https:\/\/www.linkedin.com\/company\/webkul","https:\/\/www.youtube.com\/user\/webkul\/"]},{"@type":"Person","@id":"https:\/\/webkul.com\/blog\/#\/schema\/person\/8b6a9038345794233c3cf41b15a330c4","name":"Anuj Gupta","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/webkul.com\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/a46d5e8da91ff0fecc16beee97bfb7b3a8ed158c64c69f50ddc3c1ce7d532e97?s=96&d=https%3A%2F%2Fcdnblog.webkul.com%2Fblog%2Fwp-content%2Fuploads%2F2019%2F10%2Fmike.png&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/a46d5e8da91ff0fecc16beee97bfb7b3a8ed158c64c69f50ddc3c1ce7d532e97?s=96&d=https%3A%2F%2Fcdnblog.webkul.com%2Fblog%2Fwp-content%2Fuploads%2F2019%2F10%2Fmike.png&r=g","caption":"Anuj Gupta"},"url":"https:\/\/webkul.com\/blog\/author\/anuj-gupta701\/"}]}},"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/webkul.com\/blog\/wp-json\/wp\/v2\/posts\/112192","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/webkul.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/webkul.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/webkul.com\/blog\/wp-json\/wp\/v2\/users\/171"}],"replies":[{"embeddable":true,"href":"https:\/\/webkul.com\/blog\/wp-json\/wp\/v2\/comments?post=112192"}],"version-history":[{"count":10,"href":"https:\/\/webkul.com\/blog\/wp-json\/wp\/v2\/posts\/112192\/revisions"}],"predecessor-version":[{"id":423877,"href":"https:\/\/webkul.com\/blog\/wp-json\/wp\/v2\/posts\/112192\/revisions\/423877"}],"wp:attachment":[{"href":"https:\/\/webkul.com\/blog\/wp-json\/wp\/v2\/media?parent=112192"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/webkul.com\/blog\/wp-json\/wp\/v2\/categories?post=112192"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/webkul.com\/blog\/wp-json\/wp\/v2\/tags?post=112192"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}