{"id":2711,"date":"2024-04-12T17:51:42","date_gmt":"2024-04-12T12:21:42","guid":{"rendered":"https:\/\/nuventureconnect.com\/blog\/?p=2711"},"modified":"2026-01-21T15:48:05","modified_gmt":"2026-01-21T10:18:05","slug":"create-wordpress-admin-user-via-mysql","status":"publish","type":"post","link":"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/","title":{"rendered":"WordPress: How to create Admin users via MySQL commandline"},"content":{"rendered":"<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"940\" height=\"544\" src=\"https:\/\/nuventureconnect.com\/blog\/wp-content\/uploads\/2024\/04\/image.png\" alt=\"\" class=\"wp-image-2714\" srcset=\"https:\/\/nuventureconnect.com\/blog\/wp-content\/uploads\/2024\/04\/image.png 940w, https:\/\/nuventureconnect.com\/blog\/wp-content\/uploads\/2024\/04\/image-300x174.png 300w, https:\/\/nuventureconnect.com\/blog\/wp-content\/uploads\/2024\/04\/image-768x444.png 768w, https:\/\/nuventureconnect.com\/blog\/wp-content\/uploads\/2024\/04\/image-600x347.png 600w\" sizes=\"(max-width: 940px) 100vw, 940px\" \/><\/figure><\/div>\n\n\n<p>The following blog explains how to create wordpress admin user via MySQL<\/p>\n\n\n\n<p>A <a href=\"https:\/\/wordpress.org\">WordPress<\/a> user can belong to any of the <a href=\"https:\/\/wordpress.org\/documentation\/article\/roles-and-capabilities\/\">six pre-defined roles<\/a>.<\/p>\n\n\n\n<p>&nbsp;&nbsp; \u2022 Super Admin \u2013 Has access to all features including site network administration.<\/p>\n\n\n\n<p>&nbsp;&nbsp; \u2022 Administrator \u2013 Has access to all the administration features within a single site.<\/p>\n\n\n\n<p>&nbsp;&nbsp; \u2022 Editor \u2013 Can publish and manage posts including the posts of other users.<\/p>\n\n\n\n<p>&nbsp;&nbsp; \u2022 Author \u2013 Can publish and manage their own posts.<\/p>\n\n\n\n<p>&nbsp;&nbsp; \u2022 Contributor \u2013 Can write and manage their own posts but cannot publish them.<\/p>\n\n\n\n<p>&nbsp;&nbsp; \u2022 Subscriber \u2013 Can only manage their profile.<\/p>\n\n\n\n<p>Upon installing WordPress, an Administrator account is automatically created. Thus, every WordPress installation comes with an admin user.<\/p>\n\n\n\n<p>In case a WordPress admin user loses their password, they can use the <em>Lost your password?<\/em> link and the related Email account for resetting the password.<\/p>\n\n\n\n<p>But in some case, we may not have access to this Admin account, or may not want to reset the password, but would like another Admin account created for maintenance or troubleshooting purpose.<\/p>\n\n\n\n<p>If you ever face such a scenario, we have laid out the necessary steps required to create a WordPress Admin user from MySQL commandline.<br><\/p>\n\n\n\n<p>First, let us get the necessary information about the WordPress database.<br>This information is stored in the WordPress configuration file, which is named <a href=\"https:\/\/developer.wordpress.org\/apis\/wp-config-php\/\">wp-config.php.<\/a> Identify the location of <strong><em>wp-config.php<\/em><\/strong> in the server.<br><br>And in terminal, switch to the directory containing this configuration file.<br><br>List the Database Host, Database Name, Database User, Database Password, and WordPress table prefix from WordPress configuration file.<a><br><\/a><\/p>\n\n\n\n<p><mark style=\"background-color:#000000\" class=\"has-inline-color has-white-color\"><strong># \u00a0<\/strong>grep &#8216;DB_HOST\\|DB_NAME\\|DB_USER\\|DB_PASSWORD\\|$table_prefix&#8217; wp-config.php<\/mark><\/p>\n\n\n\n<p><br>Next, login to the MySQL Server as WordPress Database user.<\/p>\n\n\n\n<p><mark style=\"background-color:#000000\" class=\"has-inline-color has-white-color\"><strong># \u00a0<\/strong>mysql -h $DB_HOST -u $DB_USER -p<\/mark><\/p>\n\n\n\n<p class=\"has-vivid-red-color has-text-color has-link-color wp-elements-60d03b950df71fbfd145781fdefbd16b\"><strong>NOTE:<br><\/strong><strong>\u21fe<\/strong><strong> <\/strong>Replace <strong>$DB_HOST<\/strong> and <strong>$DB_USER<\/strong> with&nbsp;values of Database Host and Database User acquired from output of previous command<br>\u21fe Upon receiving password prompt, use value of <strong>$DB_PASSWORD<\/strong> acquired from output of previous command<\/p>\n\n\n\n<p class=\"has-black-color has-text-color has-link-color wp-elements-60dbb47dcd9c9fc6599bb9bcb3719507\"><br>Perform the following tasks in the MySQL prompt\u2026<br><br>Use the WordPress database.<\/p>\n\n\n\n<p><strong><mark style=\"background-color:#000000\" class=\"has-inline-color has-white-color\">mysql&gt;&nbsp; use $DB_NAME;<\/mark><\/strong><\/p>\n\n\n\n<p class=\"has-vivid-red-color has-text-color has-link-color wp-elements-8ae36020035d8010ede71211fb9f0924\"><strong>NOTE:<\/strong> Replace <strong>$DB_NAME<\/strong> with name of database<\/p>\n\n\n\n<p><br>Execute the following MySQL commands to create a WordPress user.<\/p>\n\n\n\n<p><strong><mark style=\"background-color:#000000\" class=\"has-inline-color has-white-color\">mysql&gt;&nbsp;&nbsp; insert into `$DB_NAME`.`$table_prefix_users` (`id`, `user_login`, `user_pass`, `user_nicename`, `user_email`, `user_url`, `user_registered`, `user_activation_key`, `user_status`, `display_name`) values (&#8216;$WP_ID&#8217;, &#8216;$WP_USER&#8217;, md5(&#8216;$WP_PASSWORD&#8217;), &#8216;$WP_USER_NICE&#8217;, &#8216;$EMAIL&#8217;, &#8216;$WEBSITE&#8217;, &#8216;$DATE&amp;TIME&#8217;, &#8221;, &#8216;0&#8217;, &#8216;$WP_USER_DISPLAY&#8217;);<\/mark><\/strong><\/p>\n\n\n\n<p class=\"has-black-color has-text-color has-link-color wp-elements-44976dda67b3ec5f40e20cd54dc55701\"><strong>NOTE:<\/strong><br>\u21fe Replace <strong>$DB_NAME<\/strong> with value of Database Instance acquired from output of previous command.<br>\u21fe Replace <strong>$table_prefix<\/strong> with value of WordPress table prefix acquired from output of previous<br>&nbsp;&nbsp;&nbsp;&nbsp; command.<br>\u21fe Replace <strong>$WP_ID<\/strong> with the ID of to be created WordPress user.<br>\u21fe Replace <strong>$WP_USER<\/strong> with value of to be created WordPress admin user.<br>\u21fe Replace <strong>$WP_PASSWORD<\/strong> with a new strong and complex password.<br>&nbsp;&nbsp;&nbsp;&nbsp; You may use the <a href=\"https:\/\/www.lastpass.com\/features\/password-generator#generatorTool\"><strong>LastPass Password Generator<\/strong><\/a><br>\u21fe Replace <strong>$WP_USER_NICE<\/strong> with URL sanitized version of <strong>$WP_USER<\/strong>. But if <strong>$WP_USER<\/strong>&#8216;s<br>&nbsp;&nbsp;&nbsp;&nbsp; value does not have any special characters, then that value could be used for this.<br>\u21fe Replace <strong>$EMAIL<\/strong> with the Email address of to be created WordPress admin user.<br>\u21fe Replace <strong>$WEBSITE<\/strong> with the website user. This could be the main URL of WordPress website.<br>&nbsp;&nbsp;&nbsp;&nbsp; <strong>Example:<\/strong><em> http:\/\/example.com\/<\/em><br>\u21fe Replace <strong>$DATE&amp;TIME<\/strong> with the Date and Time(UTC) on which user is being created.<br>&nbsp;&nbsp;&nbsp;&nbsp; <strong>Example:<\/strong><em> 2023-09-19 10:25:47<\/em><br>\u21fe Replace <strong>$WP_USER_DISPLAY<\/strong> with the name of <strong>$WP_USER<\/strong> that will be displayed on their<br>&nbsp;&nbsp;&nbsp;&nbsp; profile page and next to their posts. Value of <strong>$WP_USER<\/strong> could be used for this.<br><br><br>Now, assign the Administrator capability for the newly created WordPress user.<\/p>\n\n\n\n<p><mark style=\"background-color:#000000\" class=\"has-inline-color has-white-color\"><strong>mysql>\u00a0\u00a0 <\/strong>insert into `$DB_NAME`.`$table_prefix_usermeta` (`umeta_id`, `user_id`, `meta_key`, `meta_value`) values (null, &#8216;$WP_ID&#8217;, &#8216;$table_prefix_capabilities&#8217;, &#8216;a:1:{s:13:&#8221;administrator&#8221;;s:1:&#8221;1&#8243;;}&#8217;);<\/mark><\/p>\n\n\n\n<p class=\"has-vivid-red-color has-text-color has-link-color wp-elements-d764503e32296f236d97e939952579f4\"><strong>NOTE:<\/strong><br>\u21fe Replace <strong>$DB_NAME <\/strong>with value of Database Instance.<br>\u21fe Replace <strong>$table_prefix<\/strong> with value of WordPress table prefix.<br>\u21fe Replace <strong>$WP_ID<\/strong> with the ID of to be created WordPress user.<\/p>\n\n\n\n<p>And then set the User Level as 10 for the newly created WordPress user. This user level pertains to the Administrator role.<\/p>\n\n\n\n<p><mark style=\"background-color:#000000\" class=\"has-inline-color has-white-color\"><strong>mysql>\u00a0\u00a0 <\/strong>insert into `$DB_NAME`.`$table_prefix_usermeta` (`umeta_id`, `user_id`, `meta_key`, `meta_value`) values (null, &#8216;$WP_ID&#8217;, &#8216;$table_prefix_user_level&#8217;, &#8217;10&#8217;);<\/mark><\/p>\n\n\n\n<p class=\"has-vivid-red-color has-text-color has-link-color wp-elements-6b91c48c09d7dfb54c8447468b541060\"><strong>NOTE:<\/strong><br>\u21fe Replace <strong>$DB_NAME<\/strong> with value of Database Instance<br>\u21fe Replace <strong>$table_prefix<\/strong> with value of WordPress table prefix<br>\u21fe Replace <strong>$WP_ID<\/strong> with the ID of to be created WordPress user.<br><br><\/p>\n\n\n\n<p>Exit from MySQL command line.<\/p>\n\n\n\n<p><mark style=\"background-color:#000000\" class=\"has-inline-color has-white-color\"><strong>mysql> <\/strong>\u00a0\u00a0exit<\/mark><\/p>\n\n\n\n<p><br>Finally, login in to the WordPress Dashboard using the new password, so that WordPress will automatically update the MD5 hash of password to a salted one.<\/p>\n\n\n\n<p>Done.<\/p>\n\n\n\n<p><br><\/p>\n","protected":false},"excerpt":{"rendered":"<p>The following blog explains how to create wordpress admin user via MySQL A WordPress user can belong to any of the six pre-defined roles. &nbsp;&nbsp; \u2022 Super Admin \u2013 Has access to all features including site network administration. &nbsp;&nbsp; \u2022 Administrator \u2013 Has access to all the administration features within a single site. &nbsp;&nbsp; \u2022 [&hellip;]<\/p>\n","protected":false},"author":98,"featured_media":2719,"comment_status":"open","ping_status":"open","sticky":true,"template":"","format":"standard","meta":{"_exactmetrics_skip_tracking":false,"_exactmetrics_sitenote_active":false,"_exactmetrics_sitenote_note":"","_exactmetrics_sitenote_category":0,"footnotes":""},"categories":[126,32,235],"tags":[5,60],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v23.3 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Create WordPress Admin User via MySQL Command Line (Step-by-Step)<\/title>\n<meta name=\"description\" content=\"Locked out of WordPress? Learn how to create a WordPress admin user via MySQL command line using safe, proven SQL queries.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Create WordPress Admin User via MySQL Command Line (Step-by-Step)\" \/>\n<meta property=\"og:description\" content=\"Locked out of WordPress? Learn how to create a WordPress admin user via MySQL command line using safe, proven SQL queries.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/\" \/>\n<meta property=\"og:site_name\" content=\"Nuventure Blog\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/nuventureco\/\" \/>\n<meta property=\"article:published_time\" content=\"2024-04-12T12:21:42+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2026-01-21T10:18:05+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/nuventureconnect.com\/blog\/wp-content\/uploads\/2024\/04\/MicrosoftTeams-image-249.png\" \/>\n\t<meta property=\"og:image:width\" content=\"1620\" \/>\n\t<meta property=\"og:image:height\" content=\"849\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Arun\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@nuventureco\" \/>\n<meta name=\"twitter:site\" content=\"@nuventureco\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Arun\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/\"},\"author\":{\"name\":\"Arun\",\"@id\":\"https:\/\/nuventureconnect.com\/blog\/#\/schema\/person\/057499b4f56467982ddebd2841cce849\"},\"headline\":\"WordPress: How to create Admin users via MySQL commandline\",\"datePublished\":\"2024-04-12T12:21:42+00:00\",\"dateModified\":\"2026-01-21T10:18:05+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/\"},\"wordCount\":810,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/nuventureconnect.com\/blog\/#organization\"},\"image\":{\"@id\":\"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/nuventureconnect.com\/blog\/wp-content\/uploads\/2024\/04\/MicrosoftTeams-image-249.png\",\"keywords\":[\"Tech\",\"Technology\"],\"articleSection\":[\"Tech News\",\"Technology\",\"wordpress\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/\",\"url\":\"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/\",\"name\":\"Create WordPress Admin User via MySQL Command Line (Step-by-Step)\",\"isPartOf\":{\"@id\":\"https:\/\/nuventureconnect.com\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/nuventureconnect.com\/blog\/wp-content\/uploads\/2024\/04\/MicrosoftTeams-image-249.png\",\"datePublished\":\"2024-04-12T12:21:42+00:00\",\"dateModified\":\"2026-01-21T10:18:05+00:00\",\"description\":\"Locked out of WordPress? Learn how to create a WordPress admin user via MySQL command line using safe, proven SQL queries.\",\"breadcrumb\":{\"@id\":\"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/#primaryimage\",\"url\":\"https:\/\/nuventureconnect.com\/blog\/wp-content\/uploads\/2024\/04\/MicrosoftTeams-image-249.png\",\"contentUrl\":\"https:\/\/nuventureconnect.com\/blog\/wp-content\/uploads\/2024\/04\/MicrosoftTeams-image-249.png\",\"width\":1620,\"height\":849,\"caption\":\"Create WordPress Admin User via MySQL Command Line (Step-by-Step)\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/nuventureconnect.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"WordPress: How to create Admin users via MySQL commandline\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/nuventureconnect.com\/blog\/#website\",\"url\":\"https:\/\/nuventureconnect.com\/blog\/\",\"name\":\"Nuventure Blog\",\"description\":\"Knowledge.transmit!\",\"publisher\":{\"@id\":\"https:\/\/nuventureconnect.com\/blog\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/nuventureconnect.com\/blog\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/nuventureconnect.com\/blog\/#organization\",\"name\":\"Nuventure Connect Private Limited\",\"url\":\"https:\/\/nuventureconnect.com\/blog\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/nuventureconnect.com\/blog\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/nuventureconnect.com\/blog\/wp-content\/uploads\/2023\/03\/logo-main-with-cartion-1.webp\",\"contentUrl\":\"https:\/\/nuventureconnect.com\/blog\/wp-content\/uploads\/2023\/03\/logo-main-with-cartion-1.webp\",\"width\":200,\"height\":89,\"caption\":\"Nuventure Connect Private Limited\"},\"image\":{\"@id\":\"https:\/\/nuventureconnect.com\/blog\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/www.facebook.com\/nuventureco\/\",\"https:\/\/x.com\/nuventureco\",\"https:\/\/www.instagram.com\/nuventure\/\",\"https:\/\/in.linkedin.com\/company\/nuventure\"]},{\"@type\":\"Person\",\"@id\":\"https:\/\/nuventureconnect.com\/blog\/#\/schema\/person\/057499b4f56467982ddebd2841cce849\",\"name\":\"Arun\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/nuventureconnect.com\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/0a04b5b09ddc5e57f13e433e4d49c47c?s=96&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/0a04b5b09ddc5e57f13e433e4d49c47c?s=96&r=g\",\"caption\":\"Arun\"},\"url\":\"https:\/\/nuventureconnect.com\/blog\/author\/arun\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Create WordPress Admin User via MySQL Command Line (Step-by-Step)","description":"Locked out of WordPress? Learn how to create a WordPress admin user via MySQL command line using safe, proven SQL queries.","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:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/","og_locale":"en_US","og_type":"article","og_title":"Create WordPress Admin User via MySQL Command Line (Step-by-Step)","og_description":"Locked out of WordPress? Learn how to create a WordPress admin user via MySQL command line using safe, proven SQL queries.","og_url":"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/","og_site_name":"Nuventure Blog","article_publisher":"https:\/\/www.facebook.com\/nuventureco\/","article_published_time":"2024-04-12T12:21:42+00:00","article_modified_time":"2026-01-21T10:18:05+00:00","og_image":[{"width":1620,"height":849,"url":"https:\/\/nuventureconnect.com\/blog\/wp-content\/uploads\/2024\/04\/MicrosoftTeams-image-249.png","type":"image\/png"}],"author":"Arun","twitter_card":"summary_large_image","twitter_creator":"@nuventureco","twitter_site":"@nuventureco","twitter_misc":{"Written by":"Arun","Est. reading time":"4 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/#article","isPartOf":{"@id":"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/"},"author":{"name":"Arun","@id":"https:\/\/nuventureconnect.com\/blog\/#\/schema\/person\/057499b4f56467982ddebd2841cce849"},"headline":"WordPress: How to create Admin users via MySQL commandline","datePublished":"2024-04-12T12:21:42+00:00","dateModified":"2026-01-21T10:18:05+00:00","mainEntityOfPage":{"@id":"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/"},"wordCount":810,"commentCount":0,"publisher":{"@id":"https:\/\/nuventureconnect.com\/blog\/#organization"},"image":{"@id":"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/#primaryimage"},"thumbnailUrl":"https:\/\/nuventureconnect.com\/blog\/wp-content\/uploads\/2024\/04\/MicrosoftTeams-image-249.png","keywords":["Tech","Technology"],"articleSection":["Tech News","Technology","wordpress"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/","url":"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/","name":"Create WordPress Admin User via MySQL Command Line (Step-by-Step)","isPartOf":{"@id":"https:\/\/nuventureconnect.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/#primaryimage"},"image":{"@id":"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/#primaryimage"},"thumbnailUrl":"https:\/\/nuventureconnect.com\/blog\/wp-content\/uploads\/2024\/04\/MicrosoftTeams-image-249.png","datePublished":"2024-04-12T12:21:42+00:00","dateModified":"2026-01-21T10:18:05+00:00","description":"Locked out of WordPress? Learn how to create a WordPress admin user via MySQL command line using safe, proven SQL queries.","breadcrumb":{"@id":"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/#primaryimage","url":"https:\/\/nuventureconnect.com\/blog\/wp-content\/uploads\/2024\/04\/MicrosoftTeams-image-249.png","contentUrl":"https:\/\/nuventureconnect.com\/blog\/wp-content\/uploads\/2024\/04\/MicrosoftTeams-image-249.png","width":1620,"height":849,"caption":"Create WordPress Admin User via MySQL Command Line (Step-by-Step)"},{"@type":"BreadcrumbList","@id":"https:\/\/nuventureconnect.com\/blog\/2024\/04\/12\/create-wordpress-admin-user-via-mysql\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/nuventureconnect.com\/blog\/"},{"@type":"ListItem","position":2,"name":"WordPress: How to create Admin users via MySQL commandline"}]},{"@type":"WebSite","@id":"https:\/\/nuventureconnect.com\/blog\/#website","url":"https:\/\/nuventureconnect.com\/blog\/","name":"Nuventure Blog","description":"Knowledge.transmit!","publisher":{"@id":"https:\/\/nuventureconnect.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/nuventureconnect.com\/blog\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/nuventureconnect.com\/blog\/#organization","name":"Nuventure Connect Private Limited","url":"https:\/\/nuventureconnect.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/nuventureconnect.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/nuventureconnect.com\/blog\/wp-content\/uploads\/2023\/03\/logo-main-with-cartion-1.webp","contentUrl":"https:\/\/nuventureconnect.com\/blog\/wp-content\/uploads\/2023\/03\/logo-main-with-cartion-1.webp","width":200,"height":89,"caption":"Nuventure Connect Private Limited"},"image":{"@id":"https:\/\/nuventureconnect.com\/blog\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/nuventureco\/","https:\/\/x.com\/nuventureco","https:\/\/www.instagram.com\/nuventure\/","https:\/\/in.linkedin.com\/company\/nuventure"]},{"@type":"Person","@id":"https:\/\/nuventureconnect.com\/blog\/#\/schema\/person\/057499b4f56467982ddebd2841cce849","name":"Arun","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/nuventureconnect.com\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/0a04b5b09ddc5e57f13e433e4d49c47c?s=96&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/0a04b5b09ddc5e57f13e433e4d49c47c?s=96&r=g","caption":"Arun"},"url":"https:\/\/nuventureconnect.com\/blog\/author\/arun\/"}]}},"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/nuventureconnect.com\/blog\/wp-json\/wp\/v2\/posts\/2711"}],"collection":[{"href":"https:\/\/nuventureconnect.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/nuventureconnect.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/nuventureconnect.com\/blog\/wp-json\/wp\/v2\/users\/98"}],"replies":[{"embeddable":true,"href":"https:\/\/nuventureconnect.com\/blog\/wp-json\/wp\/v2\/comments?post=2711"}],"version-history":[{"count":6,"href":"https:\/\/nuventureconnect.com\/blog\/wp-json\/wp\/v2\/posts\/2711\/revisions"}],"predecessor-version":[{"id":3345,"href":"https:\/\/nuventureconnect.com\/blog\/wp-json\/wp\/v2\/posts\/2711\/revisions\/3345"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/nuventureconnect.com\/blog\/wp-json\/wp\/v2\/media\/2719"}],"wp:attachment":[{"href":"https:\/\/nuventureconnect.com\/blog\/wp-json\/wp\/v2\/media?parent=2711"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/nuventureconnect.com\/blog\/wp-json\/wp\/v2\/categories?post=2711"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/nuventureconnect.com\/blog\/wp-json\/wp\/v2\/tags?post=2711"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}