Home โ€บPlugins โ€บgeo blocker
Geo Blocker โ€“ Control Site Access by Region and IP logo

Geo Blocker โ€“ Control Site Access by Region and IP

by Mohamed Shili on WordPress.org

๐Ÿ” Block or allow visitors by country. Track access attempts. View analytics. Stay in control โ€” effortlessly.

(0)
Geo Blocker โ€“ Control Site Access by Region and IP - Screenshot 1

๐Ÿ” Block or allow visitors by country. Track access attempts. View analytics. Stay in control โ€” effortlessly.

๐Ÿง  Description

Geo Blocker gives you full control over who can access your WordPress site โ€” based on visitor country and IP. Whether youโ€™re protecting content, reducing attack surface, or managing regional access, this plugin does it with precision and clarity.

๐ŸŽฏ Designed for performance, security, and ease of use.
๐Ÿ“Š Built-in analytics and access logs.
๐Ÿงญ Never get locked out โ€” admin-safe bypass included.

๐Ÿš€ Features

โœ… Access Control That Makes Sense

  • Block Selected Countries โ€“ deny access to specific regions
  • Allow Selected Countries โ€“ restrict site only to approved countries

๐Ÿงฉ Smart Blocking Actions

  • ๐Ÿ“œ Show custom message
  • ๐Ÿ” Redirect to a URL
  • ๐Ÿšซ Send HTTP 403 Forbidden response

๐ŸŒ Visual Country Selector

  • Flag icons & search bar for quick targeting
  • Filter by continent (Africa, Asia, Europe, etc.)
  • One-click select/deselect all

๐Ÿ“ˆ Analytics Dashboard

  • Summary cards: total visits, blocks, IPs
  • Hourly charts for real-time insights
  • Filter by date range & data type (accesses, unique IPs, etc.)

๐Ÿ“‹ Detailed Logs

  • See IP, country, URL, status, user agent
  • Filters out common junk (favicon, robots.txt)
  • Admin visits are auto-ignored to reduce noise

๐Ÿ› ๏ธ Admin-Proof Bypass URL

  • Special URL with bypass parameter to access login anytime
  • Prevents accidental lockouts

๐Ÿ”„ Data Export & Log Management

  • Export logs in CSV or JSON
  • Clear logs with a single click
  • Sort & search logs in the UI

๐ŸŒ External Services

This plugin uses a third-party API to determine the visitorโ€™s country based on their IP address.

  • Service used: IPWho.is
  • Purpose: To perform IP geolocation and detect the country of each visitor, allowing the plugin to block or allow access accordingly.
  • Data sent: The visitorโ€™s IP address is sent to the IPWho.is API on page load when geo-blocking is active.
  • Terms of Service: https://ipwhois.io/terms
  • Privacy Policy: https://ipwhois.io/privacy

๐Ÿ–ฅ๏ธ Screenshots

  1. ๐Ÿ“Š Dashboard Overview โ€“ See country blocks, allowed hits & total attempts
  2. ๐Ÿ”ง Blocking Rules โ€“ Choose block mode, action type, and targets. Enable or disable countries visually
  3. ๐Ÿ“‰ Analytics Graphs โ€“ View access by time, state, and IP 5. ๐Ÿ“‘ Logs Table โ€“ Deep insights with full logs of visitor attempts. Export CSV/JSON logs with one click

๐Ÿ“ฆ Installation

  1. Upload the plugin folder to /wp-content/plugins/geo-blocker
  2. Activate via Plugins Installed Plugins
  3. Go to Settings Geo Blocker
  4. Enable Geo Blocking using the toggle
  5. Choose between block or allow mode
  6. Select countries using the visual interface
  7. Pick your blocking action (message, redirect, or 403)
  8. Save settings โ€” done!

โ“ Frequently Asked Questions

How does Geo Blocker detect country?

It uses the reliable IpWhoIs API to fetch country data based on the visitorโ€™s IP.

Will it slow down my site?

Nope. Itโ€™s optimized with transient caching and smart triggers โ€” no unnecessary lookups.

Can I lock myself out?

No. Thereโ€™s a login bypass URL generated for administrators โ€” shown right on the dashboard.

Can I block specific pages?

Not yet โ€” current version works site-wide. Per-page rules may come in a future update.

Can I export visitor logs?

Yes. Logs can be exported in CSV or JSON format directly from the Logs tab.

Does it work with caching plugins?

Yes, but you may need to exclude the pluginโ€™s logic from caching. Dynamic geo checks should not be cached.

๐Ÿ—‚๏ธ Changelog

1.0.0

  • ๐ŸŽ‰ Initial release with all core features

๐Ÿ›ก๏ธ Additional Notes

Emergency Bypass

Every admin gets a custom bypass link to avoid accidental lockouts. Itโ€™s always visible in the dashboard.

Blocking Actions

Choose the experience blocked users receive:
โ€“ Custom message
โ€“ Redirect to another URL
โ€“ Send 403 Forbidden header

Logs & Privacy

Logs are stored locally in your WordPress database. The plugin sends only the visitorโ€™s IP to IPWho.is โ€” no personally identifiable information is shared or stored externally.

๐Ÿ’ก Enjoying Geo Blocker? Try Our Other Free Plugins

Looking for even more control and peace of mind? Check out our other tools:

๐Ÿ”• Notification Blocker โ€“ Hide annoying plugin notices from your dashboard without hacking core files.

๐Ÿ›ก๏ธ Fortress Login Pro โ€“ Obscure your login page, add brute-force protection, and block unauthorized access attempts with ease.

If you like Geo Blocker, youโ€™ll probably find these just as helpful. Try them out!

Active installations10+
Weekly downloads
4-66.67%
Version1.0.0
Last updated5/18/2025
WordPress version5.0
Tested up to6.8.1
PHP version7.2
Tags
access-controlcountry restrictiongeo blockinggeolocationip blocker