Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9105715
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T02:10:10+00:00 2026-06-17T02:10:10+00:00

I would use the hosting for live testing, but I want to protect access

  • 0

I would use the hosting for live testing, but I want to protect access and prevent search engine indexing.
For example (server directory structure) within public_html:

_private
_bin
_cnf
_log
_ … (more default directories hosting)
testpublic
css
images
index.html

I want index.html is visibile to everyone and all other directories (except “testpublic”) are hidden, protected access and search engines not to index.

The directory “testpublic” I wish it was public but may not be indexed in search engines, not sure if this is possible.

To do understand that I need 2 files .htaccess.
One general in “public_html” and other specific for “testpublic”.

The .htaccess general (public_html) I think it should be something like:

AuthUserFile /home/folder../.htpasswd
AuthName “test!”
AuthType Basic
require user admin123

< FilesMatch “index.html”>
Satisfy Any
< / FilesMatch>

Can anyone help me create the files with the appropriate properties? Thank you!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T02:10:11+00:00Added an answer on June 17, 2026 at 2:10 am

    You can use a robots.txt file in your root folder. All standards-abiding robots will obey this file and not index your files and folders.

    Example Robots.txt that tells all (*) crawlers to move on and index nothing.

    User-agent: *
    Disallow: /
    

    You could use .htaccess files to fine tune what your server (assuming Apache) serves out and what directory indexes are visible. In which case you would add

    IndexIgnore *
    

    To your .htaccess file to disallow indexes.

    Updated (Credit to https://stackoverflow.com/users/1714715/samuel-cook):

    If you want to specifically stop a bot/crawler and know its USER AGENT string you can do so in your .htaccess

    <IfModule mod_rewrite.c>
      RewriteEngine on
      RewriteCond %{HTTP_USER_AGENT} Googlebot
      RewriteRule ^.* - [F,L]
    </IfModule> 
    

    Hope this helps.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I use a hosting server. I would like to simply open some text files
I use CloudControl for hosting and I would like to set up a server
I have a live database on a shared hosting server. I am making some
I would like to use Azure Web Role Instances for hosting few website using
Not really a PHP developer, but I have PHP hosting and would like to
I would use a multi dimensional gaussian modell for regression. Rasmussen has a book
I would use Jmagick into an Android Project. Is it possible? I have to
I thought I would use a stored routine to clean up some of my
In .NET I would use System.Diagnostics.Trace... What would I use in C or C++
I just would like to know what format and codec would use the least

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.