There is an easy fix for the wp-pass.php 404 error you receive when trying to password protect a WordPress page using an older theme with a newer version of WordPress. If you are getting this error you may want to go ahead and update your theme or look for a newer one as this will be one of many errors you will get over time.
Why am I getting a wp-pass.php 404 error?
As stated earlier its due to updates to the WordPress structure that no longer supports outdated themes. As of WordPress version 3.4 password protection has changed, instead of using the wp-pass.php file it now uses the built in wp-login.php page with an action attribute. The file wp-pass.php has been removed and is no longer packaged with WordPress.
How to fix the wp-pass.php 404 error on password protected pages
- Either FTP into your sites theme folder or go to your WordPress Admin area and go to “Appearance -> Editor”.
- Open or select the “functions.php” file and search for “/wp-pass.php”.
- Replace “/wp-pass.php” with “/wp-login.php?action=postpass”.
- Save the file and upload if necessary and try the password protected page again
Keep in mind that if you have any custom password protected forms you will need to change the references to wp-pass.php in those as well although for most themes the instructions above alone should fix the issue.
If anyone coming across this how to article knows another method or fixes for specific themes please feel free to leave a comment so we can add it to the article. Otherwise I hope this helps those of you looking to fix the WordPress wp-pass.php 404 error and if you have any questions feel free to drop me a line.