asked in Websites + Social Media by LEGEND (7,490 points) 4 15 39
If one IP address keeps spamming your website how do you block this IP address and stop it from sending you spam message? Can you block it permanently so it can no longer access your website?
replied by (111 points) 2 10
If you want to block an ip address from accessing your website you can use this code by editing the htaccess file.

Go to to the sitess root directory and edit the .htaccess file. You may need to change the option in your control panel to show all files including hidden files (only if needed). In most cases it will not be hidden
Select htaccess file and click on edit.

Copy this code in it anywhere below rewrite mod (or below all codes)

Eg: Deny from 000.000.000.000

Note: Replace the ip address to the specific ip address instead of 000.000.000.000

Save the htaccess file and you're done.

Please log in or register to answer this question.

Related questions

0 answers 2replies
asked Aug 12, 2018 in Websites + Social Media by Poehere LEGEND (7,490 points) 4 15 39
4 answers 1replies
asked Jul 13, 2018 in Computers+Laptops by ruthmongare LEGEND (6,391 points) 5 10 21
4 answers 0replies
asked Jul 3, 2018 in Websites + Social Media by Vilma (534 points) 1 3 18
1 answer 1replies
asked Jul 13, 2018 in Websites + Social Media by Ludwig Randell (140 points) 1 4 24

2,974 questions

9,362 answers

4,528 replies

2,018 users

Most active Members
May 2019:
  1. Leyley - 60 activities
  2. Robcomp - 35 activities
  3. pmahajan18 - 19 activities
  4. leslishambly - 16 activities
  5. SmartAZ - 16 activities
  6. pinakigoswami - 15 activities
  7. Quest227 - 9 activities
  8. Nidhi Soni - 7 activities
  9. Amilia summers - 7 activities
  10. lincy - 6 activities
Most answered Members
April 2019:
  1. Leyley - 11 answers
  2. Robcomp - 4 answers
  3. leslishambly - 3 answers
  4. pinakigoswami - 3 answers
  5. Henry Mathew - 2 answers
  6. Anindita - 2 answers
  7. rsaxena50 - 1 answers
  8. bryangreene - 1 answers
  9. shailender - 1 answers
  10. marcstephens - 1 answers