Geo Blocking
Block visitors from specific countries or regions using GeoIP-based rules. VisitorFilters resolves the visitor's country from their IP address and enforces your rules in real time.
How Geo Blocking Works
- A visitor's IP address is resolved to a country using MaxMind GeoIP data.
- The resolved country code (ISO 3166-1 alpha-2) is checked against your geo block rules.
- If the country matches a block rule, the visitor receives a
403 Forbiddenresponse.
Creating a Geo Block Rule
Navigate to Rules → Geo Blocking in your dashboard. You'll see a country selector with 195+ countries available.
Steps
- Optionally give your rule a descriptive name (e.g., "Block high-risk regions").
- Use the search bar to find countries quickly by name or country code.
- Select one or more countries using the checkboxes.
- Click Create Block Rule.
Tips
- Use Select All Filtered to quickly select all countries matching your search.
- You can create multiple geo block rules to organize your blocks logically.
- Each rule can target different sites or apply tenant-wide.
Managing Existing Rules
Below the creation form, you'll see a table of all active geo block rules showing:
- Rule Name — The descriptive name you assigned.
- Countries — Country codes as badges.
- Blocks — Total number of times this rule has been enforced.
- Created — When the rule was added.
Click the trash icon to delete a rule. This takes effect immediately.
GeoIP Accuracy
Country-level GeoIP resolution is typically 95-99% accurate. Keep in mind:
- VPN and proxy users may appear from different countries.
- Some mobile carriers route traffic through centralized gateways.
- GeoIP databases are updated regularly to maintain accuracy.
Combining with Other Rules
Geo blocking works alongside other rule types. A visitor blocked by a geo rule will not be evaluated by subsequent rules. Consider using geo blocking together with:
- Rate limiting — For countries you allow but want to throttle.
- Challenge pages — Present a CAPTCHA instead of blocking.
- Whitelisting — Always allow specific IPs regardless of country.