How to Limit Connections Per IP on Your Server
Learn how to restrict the number of simultaneous connections from a single IP address on your Minecraft server to prevent bot attacks and alt abuse.
Why Limit Connections Per IP?
Bot attacks flood your server with hundreds of fake connections from the same IP address or small range of IPs. Alt account abusers use multiple accounts to circumvent bans or exploit server features. When you limit connections per ip minecraft servers allow from a single address, you block most of these attacks while still letting legitimate players (including multiple people on the same household network) connect.
Proxy-Level Limits
Velocity
Velocity does not have a built-in per-IP connection limit, but you can add one through a plugin or through your firewall. A firewall-level limit is more effective because it blocks connections before they consume proxy resources.
BungeeCord / Waterfall
BungeeCord has a built-in throttle in config.yml:
connection_throttle: 4000
connection_throttle_limit: 3
This limits each IP to 3 connection attempts within 4000 milliseconds. Adjust these values based on your needs. If players on shared networks (universities, internet cafes) report issues, increase the limit slightly.
Firewall-Level Limits
For Linux servers, iptables can limit connections per ip minecraft setups accept:
iptables -A INPUT -p tcp --dport 25565 --syn -m connlimit --connlimit-above 3 -j REJECT
This rejects new TCP connections to port 25565 when more than 3 active connections already exist from the same IP. This runs at the kernel level, which is far more efficient than application-level filtering.
For persistent rules, save them with iptables-save or use ufw:
# UFW does not natively support connlimit,
# so use iptables directly for this rule.
Plugin-Level Limits
Several anti-bot plugins include per-IP limits:
- EpicGuard: Proxy and backend plugin with connection rate limiting, geographic filtering, and bot detection.
- AntiBot: Lightweight plugin that blocks rapid connections and limits accounts per IP.
- nLogin / AuthMe: Authentication plugins that can restrict how many accounts register from one IP.
Choosing the Right Limit
A good default is 3 connections per IP. This allows a family of 3 on the same home network to play together while blocking most bot attacks. Consider your audience:
- Home networks: 2 to 4 players per household is common.
- Universities/cafes: Could have many legitimate players behind one IP. You may need to whitelist these IPs or raise the limit.
- VPN services: Many players share the same VPN exit IP. If you block VPNs, this is less of a concern.
To limit connections per ip minecraft servers should combine firewall rules with proxy-level settings. Firewall rules block connections before they consume server resources, while proxy-level limits provide finer control. For broader DDoS protection, see our DDoS mitigation guide.
Need a proxy-ready network? Astroworld Hosting supports Velocity, BungeeCord, and multi-server setups on every plan.