• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 189
  • Last Modified:

Hide Webpage

Is there a way to keep everybody from seeing a website?  Can you setup in the htaccess file only certain IP addresses that can actually view a website?

If so, can you give me an example on how to write it?

I have a website/client that does not want anybody to see but a handful of people.  Any suggestions?
1 Solution
You could create a password prompt to access the site, however preventing a domain from being accessible to the entire internet, no.
Try adding to .htaccess
order allow deny
deny from all
allow from <your_IP>

Open in new window

Gerwin Jansen, EE MVETopic Advisor Commented:
You could setup a proxy that allows 'your' clients to view the site. Other clients (not wanted ones) could be redirected to see a different site. This way 'your' site is somewhat hidden.
The best way to grant access to certain persons is using passwords.
If you use IP addresses and deny certain IPs using .htaccess, if any user is using dynamic IP, he/she will eventually end up being denied access to the site.

Featured Post

[Webinar] Cloud and Mobile-First Strategy

Maybe you’ve fully adopted the cloud since the beginning. Or maybe you started with on-prem resources but are pursuing a “cloud and mobile first” strategy. Getting to that end state has its challenges. Discover how to build out a 100% cloud and mobile IT strategy in this webinar.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now