Hosting Basic Authentication
Pressable Basic Authentication WordPress Plugin
by pressable · github.com/pressable/pressable-basic-authentication
Install
The author publishes release zips, so WP-CLI can install straight from GitHub:
wp plugin install https://github.com/pressable/pressable-basic-authentication/releases/download/1.0.2/pressable-basic-authentication.zipReadme
Hosting Basic Authentication
A WordPress plugin that forces all users to authenticate using Basic Authentication before accessing any page on the site.
Description
This plugin implements server-level Basic Authentication for your WordPress site, requiring valid credentials before any page can be accessed. It's particularly useful for:
- Sites that should not be publicly accessible
- Sites under maintenance
- Sites that need an additional layer of security before the WordPress login
Key features:
- Forces Basic Authentication for all requests (except AJAX, CRON, and CLI)
- Integrates with WordPress user database for authentication
- Handles logout functionality properly
- Prevents caching of authentication requests
- Logs failed authentication attempts
- Bypasses authentication for Super Admins in multisite installations
- Redirects authenticated users away from wp-login.php
Requirements
- WordPress 6.7 or higher
- PHP 8.1 or higher
- Server must support PHP_AUTH_USER and PHP_AUTH_PW server variables (most standard hosting environments do)
Frequently Asked Questions
Why am I getting constant authentication prompts?
This typically means:
- Your credentials are incorrect - verify your WordPress username and password
- Your server is stripping authentication headers - contact your hosting provider
- There may be a caching layer interfering - try clearing all caches
Can I bypass Basic Authentication for certain users?
In a multisite installation, Super Admins can bypass the authentication. For single site installations, you would need to modify the plugin code.
How do I disable the plugin if I'm locked out?
- Access your site via FTP/SFTP or file manager
- Rename or delete the
hosting-basic-authenticationfolder in/wp-content/plugins/ - This will deactivate the plugin
Changelog
License
This plugin is licensed under the GPL2 license. See the LICENSE file for details.
Read the full README on GitHub →
Releases
| Tag | Published | Asset | Downloads |
|---|---|---|---|
| 1.0.2 | Jul 18, 2025 | pressable-basic-authentication.zip | 845 |
| 1.0.1 | May 2, 2025 | pressable-basic-authentication.zip | 150 |
Active-site estimate ≈150 comes from the median of recent superseded releases. Method.