ipatlas

Visitors hesitate when prices are in a foreign currency

When someone in Germany or the UK opens your pricing page and sees only US dollars, they have to stop and convert the price in their head — or hunt for a currency dropdown in the footer — before they know what your product actually costs.

Showing a familiar currency symbol (€, £ or $) from the very first page view removes friction right when a buyer is deciding whether to sign up. Always keep a visible currency switcher on the page so travelers and international teams can override the default, and let your checkout confirm the final billing country and tax rate.

With one call to https://api.ipatlas.dev/v1/me from the browser (or /v1/{ip} from your server), ipatlas returns the visitor's two-letter country_code (such as "DE", "GB" or "US") and boolean is_eu in milliseconds. Looked-up IP addresses are never logged, and you can start free with 50,000 lookups a month and no credit card (or 1,000 keyless requests per day per visitor IP directly from the browser).

Example: pick a default currency in JavaScript

async function detectCurrency() {
  const saved = localStorage.getItem("currency");
  if (saved) return saved; // always respect a manual choice first

  try {
    const res = await fetch("https://api.ipatlas.dev/v1/me");
    if (!res.ok) return "USD";
    const geo = await res.json();
    if (geo.country_code === "GB") return "GBP";
    // Simplified: some EU countries (PL, SE, DK...) use their own currency, so add them as needed.
    if (geo.is_eu === true || geo.country_code === "CH") return "EUR";
    return "USD";
  } catch {
    return "USD"; // fall back quietly if offline or blocked
  }
}

Related resources

Get your free API key

Start with 50,000 free lookups a month — no credit card required. Paid plans start at $9/month with hard caps and no surprise bills.

Get your free API key Compare plans