How to Force Logout All Users in WordPress? [Login step-by-step] Best of 2021

Force Logout All Users in WordPress

Willing to force logout all users in WordPress? If ever your mind got knocked that your WordPress Website may be hacked or you just need all users to log in again.

Then, there is no default option to do that the same job in WordPress. And if you logged them out then what the way is to log in to WordPress. Might they look out for migrating their Website then click on the anchor text WordPress Migration. Here you will find out the answer to your query towards the migration.

However, In this blog, we will illustrate you how to easily force log out all users in WordPress from a very system (computer).

Why and When You Might Need to Force Log out All Users in WordPress?

If you work with a WordPress membership site or an LMS plugin. And you wish all logged in users or customers to re-login, then this blog is only for you.

Where, A plugin is defined as a type of software that contains a group of functions that can be added to a WordPress website. They are used to provide additional functionality to your application. 

You might wish to do this job for different reasons. Like, if you think that your WordPress site is hacked by someone, else if your WordPress is not working properly, then forcing logout will provide you to properly move out from your hacked WordPress site by your own PC (personal computer).

Further, if you are working up with a membership or pay per view site formula. And your fear is that users may be sharing their passwords to access content or any other job. Then this way will overcome in your hands. After making them log out from the WordPress Website, you can stop them from sharing passwords, contents. And all other things that you don’t want to share.

Next scene is that when you use a public PC (personal computer) or WiFi internet connection without safety. Means without using a VPN service or any other service which make you feel safe. And you are not sure about you logged out from that working PC or not. Then this way from the same reading blog will end all logged in sessions for you.

VPN is known as Virtual Private Network as it encrypts your data packets by providing an encrypted tunnel for the transmission of your information. 

Let’s get started! And have a look at:

How to easily logout all users in WordPress

Drive Logout All WordPress Users

For this blog, you have to edit WP-Config file called wp-config.php in WordPress. We highly suggest that you make a backup of your wp-config.php file from your PC. Before making any changes to the working file of WordPress.

Here, The wp-config.php file is a WordPress configuration file that includes necessary WordPress settings. These settings tell your website how to connect to your WordPress database, which database table prefix to use, and develops authentication keys to make your WordPress site more secure.

However, before this all, you will wish to connect your website by using FTP or with File Manager in cPanel. Once you get connected, you will find the wp-config.php file in your site’s root folder.

FTP stands for File Transfer Protocol. It is used to transfer files from one local computer to a remote website. And cPanel is also known as control panel which is basically a web hosting panel based on Linux system and provided by many hosting providers.

logout all users
Force Logout All Users in WordPress – View/Edit

After this, you may press right click and select edit option to open the file in a text editor of your PC.

Here, within your wp-config.php file you will find a code block segment. Which will look like this onto your window page. A pick to illustrate the block segment is as follows:

outline(‘AUTH_KEY’, ‘K2#m<|[UO==4Nv c+Ox+^]NH.H*6DmQRJntnj|SwKg)>,>O-z/IeRr?>5lmx`Hf:’); outline(‘SECURE_AUTH_KEY’, ‘-Qf(}6G(zB`(D*)]fe;iEw?M]PU>BY:$Ni6][email protected]<[email protected]’); outline(‘LOGGED_IN_KEY’, ‘6R6:bur.^!Q1K-/H!$]A$g3JaaO]r|B&zu~)|+C|<V,^c|f^vlhp$urvTr7>’); outline(‘NONCE_KEY’, ‘LM7}+||^qoISh4#q_ ST%#x0vke+TQD(^$W{lVQ_TyV!%,N++H)four+>uSZl6Zp.cW[3’); define(‘AUTH_SALT’, ‘PpS;[email protected]:=,RC;&0kkNXNkP -v=Lr;ghGft:?WV5vA-lje|hx4u<6-^HY+<?oRkZSY8D3zo7-8-‘); define(‘NONCE_SALT’, ‘:0Y`/h3JhwMRNCj~z[[email protected]|-s4C+XR~/-q6PfZ&Q.qFY5-]qS|L,CNbv>/z’);

It might be possible that each of these lines just have ‘put your unique phrase here’ as the second parameter in the represented block segment.

These lines from the block segments are known as authentication keys and salts of the wp-config file.

Further, you wish to visit the WordPress Salts generator page onto your PC. This page randomly generates new key strings. Which you can use in your wp-config.php file with the help of your own PC.

wp salts keys
api.wordpress.org – Force Logout All Users in WordPress

Now you wish to replace your existing keys with the new ones. That you have developed or created few second before with the help of your PC. Once you are all set, make sure to save out your changes. And upload your wp-config.php file back to the working server.

However, replacing the salts/code will automatically log out everyone from your website. And will force them to re log in.

Thus, after getting logged out, your friends/users wish to log in once again. Then there are the ways to login to WordPress website. A para to illustrate WordPress login is as follows:

WordPress Login

This para will represent you how to login to a website created through WordPress.

Login to WordPress through WordPress Tools.

These key steps will illustrate how to use WordPress tools to log into your site:

  • Log in to your host cPanel account.
  • Press the WordPress Tools link at the top of your window screen.
  • Now, on the very left side of the same working window press the Users tab.
  • Thus, below the Select WordPress select the WordPress install.
  • After that, you would wish to log in too.
  • Here, below the WordPress Users press the login icon next to the user. You are all set!

Login to WordPress Directly.

These key steps will illustrate how to login to your WordPress site directly.

Note: This formula works with most of the WordPress installations. Including: Mojo Marketplace or Simple Scripts in the cooperative market. And it might will not work if the login ways have been changed from the default setup of the WordPress. Like: if a WordPress security plugin has been customized the login URL or if the wp-admin folder has been moved away from the site of your PC.

  • Determining your login URL

Let’s determine the default URL to login to the WordPress. It should be the same URL you would use to visit your site but by using “/wp-admin” joining to the end of your site domain name. Domain name is the address of your website.

For example, if I use to visit my WordPress website by this domain name “www.example.com”. Then, I have to go with “www.example.com/wp-admin” to move onto the login screen of your website.

  • Logging In

Now, move to the login URL of your website.
And enter your WordPress username and password (which you have created) and press “Log in” from you working window page.

Note: If you are logged in very before then you will be taken to the dashboard directly. Without asking any of the username and password to your site.
However, you have access to your WordPress dashboard now. Where you can manage your WordPress site by own.

How to Improve Password Security for All Users on your WordPress website

Thus, to improve password security for all users on your WordPress Website. We consider the following cases: If you run a membership website or if you allow users to register on your site. Then users create passwords like Easy to use, remember and weak.

Whereas, weak passwords are easy to break and pose a security challenge for your website.

Well if you feel unsafe with your website and you ever think that your website is hacked. Then you might wish to reset passwords safely for all the users on your WordPress site. This will definitely allow them to develop new passwords for their accounts on the same website.

Thus, users can still use the same password that they had before with them. To avoid this all, you can enforce good or strong passwords for all the users on your WordPress site.

We hope this blog helped you in learning How to force log out all users in WordPress? [Login step-by-step].

Talk to our WordPress Customer Service Team in case of any help, dial our Toll-Free number + 1 844 897 0441.

Attain more blogs:



Leave a Reply