Skip to content

Plan picker: prices in the visitor's currency, no VAT outside the EU - #1116

Merged
helpcodeai merged 2 commits into
mainfrom
feat/plan-picker-local-currency
Oct 15, 2026
Merged

helpcodeai merged 2 commits into
mainfrom
feat/plan-picker-local-currency

Conversation

@helpcodeai

Copy link
Copy Markdown
Contributor

Matches the marketing site's pricing page (website #397 / #398).

Stripe Checkout already charges visitors outside the euro area in their own currency (Adaptive Pricing), and only EU buyers pay VAT (our only Stripe Tax registration is DE). The plan picker on /start-trial and on the licence wall showed euros and "VAT included" to everyone.

What changes (Cloud only)

  • lib/local-currency.ts:
    • useLocalPricing asks ${MARKETING_URL}/api/price-estimate once per page load, from the visitor's browser, so Cloudflare sees the visitor's country. The site allows this origin via CORS.
    • The site's answer is shape-checked; anything else counts as no answer.
  • Plan picker:
    • Prices read ≈ $22.15/month with 19 €/month exactly under them.
    • Footer: "Prices in EUR, paid in USD at checkout." ("VAT included" only for EU visitors).
  • /start-trial: the "billed today" lines show ≈ $22.15/month (19 €/month).
  • Unchanged:
    • euro-area visitors;
    • unknown countries;
    • self-hosted (no request is made);
    • an unreachable site: euros and "VAT included" as before.

Tests

  • Playwright card-trial.spec.ts: 25 passed, including 5 new:
    • helpers;
    • a US visitor (dollars first, exact euros under them, no VAT, yearly);
    • a euro visitor;
    • the site unreachable.
  • billing-awareness and neutral-signup-and-billing still pass.
  • tsc clean, eslint 0 errors.

Depends on website #398 (CORS for the Cloud origin and the vat field) being live first.

Stripe Checkout charges visitors outside the euro area in their own currency
(Adaptive Pricing), and only EU buyers pay VAT. The plan picker on
/start-trial and the licence wall showed euros with "VAT included" to
everyone, the same as the pricing page did until website #397/#398.

The app now asks anythingmcp.com/api/price-estimate from the visitor's
browser (Cloud only, so Cloudflare sees the visitor's country) and shows
"≈ $22.15/month" with "19 €/month exactly" under it, "Prices in EUR,
paid in USD at checkout.", and drops "VAT included" outside the EU.
Euro visitors, self-hosted instances and an unreachable site keep euros.
@helpcodeai
helpcodeai enabled auto-merge (squash) October 15, 2026 19:33
@helpcodeai
helpcodeai merged commit 737dd89 into main Oct 15, 2026
14 checks passed
@helpcodeai
helpcodeai deleted the feat/plan-picker-local-currency branch October 15, 2026 19:40
@github-actions github-actions Bot locked and limited conversation to collaborators Oct 15, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant