Not really a WP question, but I do this with dev sites. I don’t think I can give you an absolute answer as to search engines’ behavior, but speaking from experience, adding authentication like htpasswd retroactively would cause an eventual departure from search results. Adding auth proactively has produced effective results for me. The search engine hits the auth, then is left with a 401 error.
You can also try asking Google to in-undex your stuff if you need to. The site needs to be registered in Google Websmater Tools/Search Console. https://support.google.com/webmasters/answer/1663419?hl=en
Related Posts:
- Default .htaccess file for WordPress?
- Which one does WordPress prioritize when it comes to php.ini, wp-config and .htaccess?
- Does this .htaccess security setting really work?
- htaccess problem after saving Settings
- File and directory permissions
- htaccess disable WordPress rewrite rules for folder and its contents
- htaccess https redirect from www to non-www
- Name-based virtual host configuration in Apache seems to cause a “500 Internal Server Error”
- Isolating WordPress to a subfolder
- How disable SSL redirect for specific URL?
- Error:406 not acceptable
- .htaccess Rewrite URL WordPress
- A plugin changes my .htaccess file and I can’t access httpd.conf as that’s a shared server
- What is the role of .htaccess file in WordPress?
- Remove File Extension for Page Outside of WordPress
- How can I code my plugin to safely modify .htaccess?
- HTAccess stops me from accessing WordPress Dashboard links
- different child theme for subdomain
- How do I edit the htaccess file to optimize my website?
- Block only external access to wp-cron.php on OpenLiteSpeed
- .htaccess rewrite rule puzzle
- Site searches by Python for non-existent assets
- Allow logged in users who doesn’t belong to whitelisted ips
- WordPress On subfolder
- Best way to redirect site in subdirectory to root?
- Missing slash after moving site to subfolder
- WildCard SSL with wordpress subdomain
- Override htacces rule only for specific directory
- How To Allow Only Specific User Agent To Access a URL?
- browser caching not disabled after disabling in .htaccess
- How to ignore folder in site root while accessing a URL
- Transfer to HTTPS – mixed content on main page only [closed]
- Htaccess redirect after changing Language URL format
- How do I test to ensure that my wp-config file is protected?
- How can I enable keep alive (Not accessing to Apache)
- Adding a SSL Certificate
- HTTP sitewide, except for: wp-admin, and 2 custom directories
- WordPress installed in root, need second in subdirectory with different domain
- htaccess has broken my site
- mod_rewrite loop, redirecting http to https on certain section of wordpress blog
- .htaccess in subdir gets ignored by WordPress’ own .htaccess in /
- TimThumb & htaccess : clean url
- Rules in .htaccess only if the requested URL is /wp-admin
- What to write in the htaccess in order to detect browser language and point accordingly?
- Only Allow Front End Access
- .htacess rewrite condition: page to seconddomain/page
- .htaccess RewriteCond excluding directories does not work when there is an .htaccess or php.ini in subdirectory
- Separate 404 page for WordPress in subfolder
- Weird behavior of Dashboard, must be core files
- 404 error Additionally 403 Forbidden error on a URL
- Remove trailing slash after .html extension
- Does WP suppresses .htaccess if permalinks are disabled?
- Need help rebuilding lost htaccess file
- I have a page using a pretty url and a mod_rewrite rule matching it. I expected it to give an error but it’s working. Why?
- How do I setup htaccess for 301 redirects, post Joomla to WordPress migration? [closed]
- How to rename index.php to home.php
- Strange behaviour of is_user_logged_in() and get_current_user_id()
- Hide a subdirectory on my website hosting
- Creating a copy of a website in a subdirectory, wp-admin redirect problem
- disable WordPress 404 for one specific page/folder to receive actual php errors
- .htpasswd asking for authentication on home page
- WordPress login fail after .htaccess domain redirect
- Redirect to new domain with .htaccess [closed]
- I am new in word pres my font awesome is not allow
- Access sub-domain when root public_html is protected with .htaccess password
- Redirect https://www.subdomain.domain.com is not redirecting to subdomain.website.com [closed]
- htaccess redirect throws an error: PHP Catchable fatal error: Object of class WP_Error could not be converted to string
- Can’t access htaccess [closed]
- WordPress permalinks confusion
- .htaccess redirect not properly working [ ?utm_source=]
- Should I prevent access to .htaccess and wp-config.php files?
- Basic Auth .htaccess on wp-login, but allow logout from woocommerce
- Why my WordPress Site Asking for HTTP Authentication?
- htaccess redirects invalid request to home page not 404
- WordPress How to rewrite URL for custom pages
- How to properly give WordPress its own directory
- Downloading zip or tar.gz inside WordPress installation?
- WordPress permalinks is wrong. It wants me to change my htaccess file. But then site crashes
- Clicking PUBLISH Now Redirects to 404 PAGE NOT FOUND
- Unable to find ‘full-path’ to my 404.php file
- Question with .htaccess and wp-login.php prevention
- Use htaccess to redirect wordpress non-existent page to homepage
- WordPress RSS feed to external XML
- I can access subdirectory, but not files within it
- htaccess old php pages to new wordpress ones
- htaccess mod_rewrite not working
- different CNAME to corresponding subfolders
- block seacrh engines for all pages EXCEPT homepage
- Giving WordPress it’s own directory and using .htaccess Directory Index
- Allowing access to certain WordPress created pages or posts with htaccess / htpasswd
- Restrict download files from not generated Urls
- How to change wordpress news root url
- Problem with All in one WP Migration – only works the home page
- htaccess – Server Subdirectory With Different Name Than URL Subdirectory
- WordPress sections in htaccess kills FrontPage permissions
- How can I stop WordPress from catching URL’s for static pages that I save on my server
- Enable webp support Nginx+Apache reverse proxy with moss.sh [closed]
- How To Add CSP frame ancestors in WordPress Website? [closed]
- The connection to “domain” is not secure
- How do I modify each instance of setcookie?