L Skippednote Locale edge demo
Locale · 0001Cloudflare Pages Function

Regional preferences at the edge

Live at CMH
Detected country
US
Edge colo
CMH
Selected by
Cloudflare location
Preference
Location default
01

Locale preference

Cloudflare detects the request country and supplies regional language and currency defaults. Save with a demo name to sync region, language, and derived currency across devices.

Enter the same name on another device to load its KV-backed preference. This public demo does not authenticate names.
Demo modeEmulate another visitor countryThis changes the country used by the Function without changing your IP address.
Detected defaultUnited States / English / USD
Region currencyDerived by the Function
USD
Use location default
02

Application contract

Resolved locale

United States / English / USD

region=US language=en currency=USD
City
Columbus
Timezone
America/New_York
Continent
NA
03

Resolution order

Default
A

Cloudflare location

Country metadata selects the first regional language and currency without setting a default locale cookie.

Priority
B

KV profile

A stored named preference wins across devices; anonymous preferences remain in an HttpOnly cookie.

Action
C

Human override

Choosing a new region updates KV and the local cookie; currency follows the region.

View Function response
{
  "language": "en",
  "region": "US",
  "currency": "USD",
  "source": "Cloudflare location",
  "detected": {
    "language": "en",
    "region": "US",
    "currency": "USD"
  },
  "country": "US",
  "actualCountry": "US",
  "simulatedCountry": null,
  "isSimulated": false,
  "city": "Columbus",
  "colo": "CMH",
  "continent": "NA",
  "timezone": "America/New_York",
  "hasSavedPreference": false,
  "hasStoredProfile": false
}