IP2Location Country Blocker

IP2Location Country Blocker

Developed By hexasoft

Compatible with WHMCS v8.9

IP2Location Country Blocker


You can use this add-on to block visitors from the selected countries from accessing your WHMCS website. This plugin use the IP address to geolocate the location of the visitor for blocking purposes. A custom message will be displayed to the blocked visitors.


  • Allow specified country to login into your WHMCS administrator.
  • Filter visitors from high risk countries from making any purchases.
  • No need to set up a relational database for blocking. The plugin will perform the lookup from the BIN file.


  • Allows user to select multiple countries for blocking.
  • Allows user to customize the error message for blocked users.
  • Supports both IPv4 and IPv6 addresses.
  • Supports both IP2Location Free LITE database and commercial database. Download links below:
    • IP2Location Free LITE database at https://lite.ip2location.com
    • IP2Location Commercial database at https://www.ip2location.com
  • Monthly database updates available for both free LITE and commercial database.


How to install the add-on?

  1. Upload all files under whmcs to WHMCS installation folder.

  2. In WHMCS admin page, go to Setup - Addon Modules. Activate IP2Location IP-Country Blocker.

  3. Configure the add-on to enable Full Administrator access.

  4. Go to Add-ons - IP2Location IP-Country Blocker to customize your settings.

Can I block more than one country?

Yes, you can block one or multiple countries. Use CTRL + Click to select multiple countries from the list.

Where can I download IP2Location database?

You can download the IP2Location database for free from https://lite.ip2location.com or the commercial version from https://www.ip2location.com.

Can I display my own message for blocked users?

Yes, you can insert any message you want via the setting page.



5 stars
4 stars
3 stars
2 stars
1 star

piticu iulian @piticu2544

August 10, 2023 at 03:18:31 PM

is dont work anymore
Database file is corrupted. Please manually download IP2Location BIN database and upload to

  • 10 months ago
  • Version Number 2.4.1

Turgut Kalfaoglu @turgut2705

March 5, 2022 at 05:26:58 AM

The code that's inside, blocked.php, shows that it uses mysql_fetch_array .. .I thought all mysql_?? functions went out with PHP 5?

...and how do we blacklist a C class?

  • 2 years ago
  • Version Number 2.4.1
  • Edited

Natan Ray @natan7042

May 30, 2019 at 10:02:46 PM

This module is unable to track visitors properly. Also unable to block specific countries. Totally useless.

  • 5 years ago
  • Version Number 2.1.1

Yuri Kusnezow @yuri5240

March 21, 2019 at 04:11:37 PM

The module works in MOST cases. It uses geoip so the location tagging is not perfect. But hey, the module is free and actually it helps us a lot. 5 stars

  • 5 years ago
  • Version Number 2.1.1

n3m0 @nm3285

October 15, 2018 at 08:22:48 AM

I have no idea why previous reviewer said this is not work. This module works good on my site. I got latest whmcs, and using php 5.6. If you follow the instruction carefully, there will be no problem at all!. I have tested as well to access my site using the ip from the country i blocked, it works good!
I registered in this marketplace solely just to say my thanks to the developer for the good job. Thank you!

  • 5 years ago
  • Version Number 2.1.1

Jesper Madsen @jesper9993

August 2, 2018 at 02:07:11 PM

Unfortunately does not work

  • 5 years ago
  • Version Number 2.1.0

Version Compatibility

Compatible with WHMCS v8.9

Full Version Compatibility

  • Selected versions of WHMCS v8.9
  • Selected versions of WHMCS v8.8
  • All versions of WHMCS v8.7
  • All versions of WHMCS v8.6
  • All versions of WHMCS v8.5
  • All versions of WHMCS v8.4
  • All versions of WHMCS v8.3
  • All versions of WHMCS v8.2
  • All versions of WHMCS v8.1
  • All versions of WHMCS v8.0
  • All versions of WHMCS v7.10
  • All versions of WHMCS v7.9
  • All versions of WHMCS v7.8
  • All versions of WHMCS v7.7
  • All versions of WHMCS v7.6
  • All versions of WHMCS v7.5
  • All versions of WHMCS v7.4
  • Selected versions of WHMCS v7.3
  • All versions of WHMCS v7.2
  • All versions of WHMCS v7.1
  • All versions of WHMCS v7.0

Support for this product

The best place to start if you need help with a specific product is to contact the developer. All WHMCS Marketplace developers have both a website and support URL listed.

Developed By hexasoft


v2.5.1 Released January 10th, 2024

Latest Version

Fixed database download issue with some hosting environments.


Previous Versions

v2.5.0 Released January 8th, 2024

View/hide detailed changelog

Added IP2Location.io Geolocation API service lookup.


v2.4.1 Released October 20th, 2021

View/hide detailed changelog

Minor bug fixes.


v2.4.0 Released March 4th, 2021

View/hide detailed changelog

  • Added setup wizard.
  • Improved database download process.
  • Updated UI to match Bootstrap 4 layout.


v2.3.0 Released October 2nd, 2020

View/hide detailed changelog

  • Added ability to white-list multiple IP address.
  • Added ability to black-list multiple IP address.
  • Updated country list to searchable auto complete list.


v2.2.0 Released February 4th, 2020

View/hide detailed changelog

  • Enhanced IP address detection.
  • Bundled supports for PHP 5.6, PHP 7.1 and PHP 7.2 and above.


v2.1.1 Released October 9th, 2018

View/hide detailed changelog

  • Fixed database update issue.
  • Added IPv6 Database update.


v2.1.0 Released November 14th, 2017

View/hide detailed changelog

Updated to use download token for IP2Location BIN database update.


v2.0.1 Released September 29th, 2017

View/hide detailed changelog

  • Fixed proxy IP detection.


See also

FREE ResellerClub Tools v2

Working comfortably with ResellerClub's products and services through your WHMCS system requires additional tools.

WHOIS for Clients

WHOIS for Clients

Dropbox Backup for WHMCS

This module will integrate WHMCS with Dropbox to upload a copy of WHMCS database onto the cloud. You will never have to worry about losing data any more.

Website Monitoring

Checks every website you host and alerts you if there are problems

Software Licensing Addon

Build, License & Distribute Your Own Apps using WHMCS