Block suspicious IP addresses by limiting how many failed WordPress login attempts can happen before a lockout. The cleanest way to do this is with the Login LockDown WordPress plugin, then set strict rules for retries, lockout time, and repeat offenders. This matters because stolen credentials are still a common cause of breaches; Verizon’s 2024 report links stolen credentials to 24% of breaches [source: Verizon].

TLDR: Install Login LockDown, set a limit such as 3 failed attempts within 5 minutes, and lock the IP for at least 60 minutes. If one IP tries 18 bad passwords in 20 minutes, it should not get a nineteenth try. For a small business site with 2 admins, even 10 failed logins per hour is worth treating as suspicious. Review lockout logs weekly and block repeat IPs longer.

Why failed login attempts are a real risk

Most WordPress login attacks are boring. That is the problem. Bots hit /wp-login.php again and again with common usernames, leaked passwords, and old admin emails. They do not need skill. They just need time.

Without rate limits, WordPress keeps answering. Your server works harder. Your logs fill up. Your real admins may see slow login pages. It drives me crazy that one weak login page can waste more server resources than a dozen normal visitors.

Blocking IPs after repeated failures cuts off this pattern early. It does not replace strong passwords or two-factor authentication, but it stops cheap brute-force noise before it becomes a bigger issue.

a close up of a screen with numbers on it security dashboard data protection alerts

Use Login LockDown for IP-based blocking

Login LockDown records the IP address and timestamp of failed login attempts. When too many failures happen in a short window, it blocks that IP from trying again for a set period.

You can install it from the official plugin page at WordPress.org. You can also review the plugin’s main site at WP Login Lockdown.

The setup is simple, which is good. Security tools should not make you click through ten screens just to stop obvious junk traffic.

Recommended lockout settings

Start with firm rules, then adjust if real users complain. For most small and medium WordPress sites, these settings are a solid baseline:

  • Max login retries: 3 failed attempts
  • Retry time period: 5 minutes
  • Lockout duration: 60 minutes
  • Longer lockout for repeat offenders: 24 hours if the same IP keeps returning
  • Admin alerts: Enable email alerts only for repeated lockouts, not every single failure

That last point matters. Too many alerts become noise. After a week, nobody reads them. Send alerts when there is a pattern, such as 5 locked IPs in one hour or repeated failures against an admin account.

How to configure the plugin

  1. Log in to your WordPress admin dashboard.
  2. Go to Plugins, then Add New.
  3. Search for Login LockDown.
  4. Install and activate it.
  5. Open the plugin settings page.
  6. Set the retry count, time window, and lockout length.
  7. Save the settings.
  8. Test with a non-admin account if possible.

Do not test from your only admin account unless you know how to remove a lockout. Expect to waste time on that once if you rush. It is better to test from a second browser, a test user, or a separate network.

security privacy and performance status with fix options plugin settings failed attempts lockout timer

When should you block an IP permanently?

Permanent blocks sound nice, but use them with care. Many users share IP addresses through offices, hotels, mobile carriers, and VPNs. If you block too aggressively, you may block real people.

A better rule is this:

  • First event: 60-minute lockout
  • Second event in 24 hours: 6-hour lockout
  • Third event in 24 hours: 24-hour lockout
  • Repeated attacks over several days: consider a firewall-level block

If the same IP keeps attacking the same username, that is a stronger signal. If the usernames are random, it may be a broad bot scan. Both are bad, but the first one deserves closer review.

What to watch in your login logs

Login LockDown logs help you spot patterns. Check them at least once a week. For busy sites, check daily.

Look for:

  • Many failures from the same IP address
  • Login attempts against admin, administrator, or staff names
  • Attempts at strange hours, such as 2 a.m. site time
  • Bursts of failures every few minutes
  • Countries or regions where you have no users or staff

Do not panic over one failed login. People mistype passwords. Worry about repetition. A single bad password is normal. Thirty failures from one IP in an hour is not.

Pair IP blocking with better login hygiene

IP blocking is only one layer. Add these basics too:

  • Use long, unique passwords for every admin.
  • Remove unused admin accounts.
  • Avoid the username admin.
  • Limit who has administrator access.
  • Keep WordPress, themes, and plugins updated.
  • Use secure hosting with server-side logging.
a security and privacy dashboard with its status secure pdf password protection business documents

Keep the rules strict, but fair

The goal is not to block every mistake. The goal is to stop repeated abuse without locking out real users all day. Start with 3 attempts in 5 minutes and a 60-minute lockout. Then review the logs after a week.

If you see constant attack traffic, raise the lockout time. If real users keep getting blocked, check whether they are sharing one office IP or using outdated saved passwords. Small tuning changes can save support time and reduce risk.

A WordPress login page should not give bots unlimited chances. Set a limit, watch the logs, and make repeated failure expensive for attackers.

About the Author

WP Webify

WP Webify

Editorial Staff at WP Webify is a team of WordPress experts led by Peter Nilsson. Peter Nilsson is the founder of WP Webify. He is a big fan of WordPress and loves to write about WordPress.

View All Articles