In cPanel
In cPanel, go to the following section: Security > IP Blocker
In the designated field, enter the IP address you want to block. Then click Add.
The IP address will be added to the list of blocked addresses.
In .htaccess File
Please note that you can block specific IP addresses directly through your website’s .htaccess file. To do so, log in to cPanel, open File Manager → public_html, locate the .htaccess file, then right-click and select Edit.
Add the IP address you wish to block, save the changes, and test your website to ensure it is functioning normally.
Order Allow,Deny Deny from 1.2.3.4 Allow from all
If you need to block multiple IP addresses, add a separate rule for each IP address.
Order Allow,Deny
Deny from 1.2.3.4
Deny from 5.6.7.8