> ## Knowledge Base Index
> Fetch the complete knowledge base index at: https://help.serverfreak.com/sitemap.xml
> Use this file to discover available pages before exploring further.
> Pure-Markdown content can be obtained by appending a '.md' suffix to the content URLs listed in the sitemap (without the trailing slash).

# How to Make Your Website Inaccessible to All Visitors Except Yourself?

In the previous tutorial [How to Deny an IP or Domain in cPanel](/en/article/how-to-deny-an-ip-or-domain-in-cpanel-fm1oit/), you can block any ip addresses from accessing your cPanel but in this tutorial you can make your website inaccessible to all visitors except yourself. 


Here are the steps for your reference:


### .HTACCESS METHOD

1) Open your web browser and visit **www.whatismyip.com** in order to obtain your current ip address.



2) Once you have identified your IP address, open a notepad, copy and save it there. 
Login to your **cPanel**.



3) Navigate to **File Manager** and don’t forget to click **show hidden files** and go to **public_html** folder.



4) Create a file and name it **.htaccess** and insert the following code:


###########
Order deny,allow
Deny from all
Allow from 175.136.222.102
###########



Please do take note that the ip address 175.136.222.102 is just an example.

Once done, save it and clear your browser’s cache.

After that, all your visitors won’t able to view your website except you, unless you remove the codes above.