Skip to content
Shahid Malla
Billing and automation In Stock

Geo Currency by Visitor Country for WHMCS

New visitors see WHMCS prices in their own country's currency, set from Cloudflare's country header, while their own choice always wins.

WHMCS Built for WHMCS 9 PHP 8.2+

What does the geo currency addon do?

WHMCS shows every new guest your default currency until they find the switcher, so a visitor from London may read your whole price list in dollars. This addon decides the starting currency once, on the first client area request of a guest session. It reads the visitor's country from Cloudflare's CF-IPCountry header and looks it up in a list you write, one line per country, such as "GB = GBP". Every other country gets a fallback currency you set, or WHMCS' default if you leave it empty.

The decision runs while WHMCS loads its hook files, before the page reads the currency, so the first page is already in the right currency with no redirect. If the session has not started at that point, a second hook decides instead and reloads that one page once, for normal page views only.

When does it leave the currency alone?

SituationWhat happens
Signed-in clientThe account currency stays
Visitor picked a currencyTheir choice stays, now and for the rest of the session
Cart already holds itemsThe cart currency stays
Search engine, link preview or monitorNever switched, so crawlers see your default prices
Admin area, API and cronNever touched
Currency not set up in WHMCSWHMCS' default currency is used

What does the admin page show?

A status page checks your own request: the country header it received, whether it came from a Cloudflare address, whether your server already restores visitor addresses, and the currency a new guest from your location would get. It lists your mapping as WHMCS will use it, with each currency marked as set up or missing, and has a visitor simulator for any country, signed in or not, with or without a cart. It also tells you if a third-party geolocation hook is already setting currencies, so two tools do not fight over the same session.

Who is it for?

WHMCS sellers with customers in several countries who already have more than one currency set up and run their site through Cloudflare. It fits hosts who want visitors from the UK, Europe or Australia to see local prices from the first page without hiding the currency switcher.

What do you need, and what are the limits?

Requirements: WHMCS 9, PHP 8.2 or newer, the currencies you map set up in WHMCS, and Cloudflare with IP Geolocation switched on. Without Cloudflare, it can read a fallback header or a server variable your web server sets, such as GEOIP_COUNTRY_CODE.

Limits: it only picks the starting currency. Prices still come from what you set for each currency in WHMCS, and it does not add a currency switcher or change exchange rates. It creates no tables and keeps no logs; the session holds only the outcome, never the country or the IP address.

It costs $29 once for a lifetime license with twelve months of updates and support, an instant download and license key, and a seven-day refund window.

Key features

  • Currency picked from Cloudflare's CF-IPCountry header
  • Country to currency list, one line per country
  • Fallback currency for every other country
  • Decided once per guest session, before the first page renders
  • Visitor choice, client account currency and filled carts always win
  • Search engines, link previews and monitors are never switched
  • Header trusted only from Cloudflare IP ranges, or always
  • Optional fallback header or server variable
  • Admin status page with a visitor simulator

Why customers buy this module

  • →Overseas visitors see familiar prices from the first page
  • →Search engines keep seeing your default currency
  • →No database tables and no personal data stored

Frequently asked questions

Will Google see my prices in a different currency?

<p>No. A built-in list of search engines, link previews, speed testers, monitors and HTTP libraries is never switched, and a request with no user agent counts as a crawler too. You can replace the list with your own in the settings. Crawlers therefore see your WHMCS default currency, the same as before.</p>

My server already restores visitor IPs from Cloudflare. Does it still work?

<p>Yes. By default the country header is trusted only when the request comes from a Cloudflare IP range. If your server replaces that address with the visitor's own, for example through mod_remoteip, switch the trust setting to Always. The admin page spots this situation and tells you which setting fits.</p>

Can someone fake the country header to get a cheaper currency?

<p>It gains them nothing. Any guest can already pick any currency in the WHMCS switcher, and prices for each currency are the ones you set. The stricter trust mode only stops direct hits on your origin server from being priced by a header someone else added.</p>

Technical specifications

WHMCS
Built for WHMCS 9
PHP
8.2+
Country source
Cloudflare CF-IPCountry, or a fallback header or server variable
Data stored
Session outcome only, no tables or logs
License
Lifetime, 1 year of updates and support included
Delivery
Instant download and license key
Refund window
7 days