Question

How can I regain Admin access - appears to have lost all users with Admin rights

We have a Wordpress site that was set up by Creative Suburbs, an engagement company that has since gone out of business.

Having some experience in using Wordpress, I have been making some updates but when trying to change menus, cannot access anything. Checked with the now owner of the site from Melbourne Water and we only have one Profile set up which is not a Super User or Admin, so cannot make any of the required changes to Menus etc.

Is this something that you can assist with?

Subscribe
Share

Submit an answer
You can type!ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Hi @nino1256267,

There are a lot of way to change your user from User to Administrator. I’ll go for using WP-CLI. WP-CLI is the command-line interface for WordPress. You can update plugins, configure multisite installations and much more, without using a web browser directly in the terminal.

  • Install WP-CLI

The WP-CLI is available as .phar (PHP Archive) file. You can download this archive file using Wget or Curl command. I’ll be using wget

ssh root@YourDropletIP

As soon as you are in, execute the following commands

wget https://raw.githubusercontent.com/wp-cli/builds/gh-pages/phar/wp-cli.phar

After the file has been downloaded, make it executable

chmod u+x wp-cli.phar

Move the file to be an executable accessible on the whole system

sudo mv wp-cli.phar /usr/local/bin/wp

Now you have wp-cli install. **Now to the fun and useful stuff **. Go to your DocumentRoot

cd /path/to/your/website

where /path/to/your/website is the actual directory your website is at. As soon as you are there, execute the following command

wp user update USERNAME --role=Administrator

Please remember to change ‘USERNAME’ with the actual user you wish to set as an Administrator.

That’s it, you have now made your user an administrator. For the changes to take effect, logout and login to the said user.

Regards, KDSys