Denying Access To Specific IP Addresses

Denying Access To Specific IP Addresses


You can use the your web statistics tool to find specific visitor IP addresses. 



Blocking An IP Address

    1. Log in to cPanel.
    2. Scroll down to the "Security" section, and click "IP Blocker".
    3. Enter the domain or IP address you would like to block underneath "Add an IP or Range"
    4. Click "Add".



Unblocking An IP Address

    1. Log in to cPanel.
    2. Scroll down to the "Security" section, and click "IP Blocker".
    3. Find the IP that you wish to unblock underneath "Currently-Blocked IP Addresses".
    4. Click "Delete".
    5. To confirm, click "Remove IP".



Deny All

It is also possible to deny all traffic. This is done via the .htaccess file. The command to deny all incoming traffic is "deny from all". You must add exceptions for anyone you wish to be able to see the site, even yourself. To allow specific IP addresses, the command is "allow from xxx.xxx.xxx.xxx" where the xxx.xxx.xxx.xxx is replaced with the IP address you wish to allow access. It is a good idea to add comments to explain what the allowed IP exceptions are, such as "#home" or "#work".


  • 79 Users Found This Useful
Was this answer helpful?

Related Articles

Do you offer password protected directories?

By default, cPanel allows you to password protect directories in your account that you wish to...

Why can't I log into my cpanel or webmail?

There various issues that you may not be able to login to your cPanel or WebMail. We have...

Custom Error Pages

Creating your own error pages can be accomplished through cPanel. After logging in, under...

Requesting a New cPanel Password

Resetting Your cPanel PasswordYou can reset your cPanel password from the cPanel login screen....

Secure cPanel Login

Using Shared SSL to Access cPanel Use https, enter your site's IP address, and the secure port...