Force Login
Easily hide your WordPress site from public viewing by requiring visitors to log in first. As simple as flipping a switch. Make your website private until it’s ready to share publicly, or keep it private for members only. Features WordPress Multisite compatible. Login redirects visitors back to the
Easily hide your WordPress site from public viewing by requiring visitors to log in first. As simple as flipping a switch.
Make your website private until it’s ready to share publicly, or keep it private for members only.
Features
- WordPress Multisite compatible.
- Login redirects visitors back to the url they tried to visit.
- Extensive Developer API (hooks & filters).
- Customizable. Set a specific URL to always redirect to on login.
- Filter exceptions for certain pages or posts.
- Restrict REST API to authenticated users.
- Translation Ready & WPML certified.
Bug Reports
Bug reports for Force Login are welcomed on GitHub . Please note that GitHub is not a support forum.
Upload the Force Login plugin to your site, then Activate it.
1, 2: You’re done!
1. How can I specify a redirect URL on login?
By default, the plugin sends visitors back to the URL they tried to access. However, you can redirect users to a specific URL by adding the built-in WordPress filter login_redirect to your functions.php file.
2. How can I add exceptions for certain pages or posts?
You can bypass Force Login based on any condition by adding the following filter to your functions.php file.
You may use the WordPress Conditional Tags in your code.