Knowledgebase
Portal Home > Knowledgebase > Security > How to ban any IP Address via .htaccess?
How to ban any IP Address via .htaccess?
If someone is trying to hack your website or you want to block their IP Address, you can add this line to your .htaccess file.
order allow,deny
deny from IP-ADDRESS
allow from all
Replace "IP-ADDRESS" with the IP Address you want to block.
Also Read
How to disable directory browsing using .htaccess?
3259
How to Disable the Two-Factor Authentication on Your cPanel Account?
3972
How to blacklist an IP Address to deny it access to your website?
3803
How to Enable the Two-Factor Authentication on Your cPanel Account?
4565
How to protect your .htaccess file?
3524