Random Location Generator
By Marko Visic · Updated Oct 11, 2026
Generate a random place anywhere on Earth, on land, in a country or state, or near you, or pick a random town. Every point opens a full card: the country and region, nearest towns with distance and direction, elevation or ocean depth, local time and day or night, today’s sunrise and sunset, nearby Wikipedia, and links to open it in maps. Free, no sign-up.
Example: today’s random place (Nov 5, 2026)
A fresh land point, seeded by today’s date, generated and looked up on the server — the same card the tool shows when you select a point (elevation needs the live terrain tiles, so it appears in the interactive card above).
What you get for every random place
Select any point and its card fills in from these sources. Everything but elevation and the Wikipedia search is bundled with the site, so it loads fast and works offline-first.
| Field | Source |
|---|---|
| Country and admin-1 region (state, province, department) | Natural Earth 10m administrative polygons (public domain) |
| Sea or ocean name (for water points) | Natural Earth 10m marine polygons (public domain) |
| Landform region and continent | Natural Earth 10m physical polygons (public domain) |
| Nearest towns — population, distance (km/mi), compass direction | GeoNames cities1000 (CC BY 4.0) |
| Elevation or ocean depth (approximate) | AWS Terrain Tiles — USGS 3DEP, SRTM, GEBCO/ETOPO |
| Local time zone | IANA time zone database |
| Day or night now, today’s sunrise and sunset | Astronomy Engine |
| Nearby articles within 10 km | Wikipedia GeoSearch (links only) |
Random points done correctly — equal-area on the sphere
Most "random location generator" sites use the simplest possible math: pick a random latitude between -90° and +90°, pick a random longitude between -180° and +180°. Done. This is wrong.
Earth is a sphere, not a flat rectangle. The area of a 1° latitude × 1° longitude cell shrinks as you approach the poles, by a factor of cos(latitude). If you sample latitude uniformly, you generate points proportionally to lines of latitude — but each line at high latitude wraps a much smaller circumference than the equator. Result: random points pile up near the North and South Poles, with proportionally too few near the equator. Common online tools have this exact bug; a "random place on Earth" produced by a naive generator is about 2.9 times as likely per square kilometer at 70° N as at the Equator (1 / cos 70°).
The fix is to sample sin(latitude) uniformly, not latitude itself. The formula: lat = asin(2u − 1) × 180/π where u is uniform in [0, 1]. The asin compensates for the cos(lat) area element. The result is genuinely uniform by surface area on the sphere — and it is the math we use.
How to use the random location generator
A few steps. Defaults are sensible — most users only set the mode and tap Generate.
- Pick a mode. Anywhere on the sphere returns a uniformly distributed random point on Earth — about 71% of which will land in the ocean. Land only re-rolls until the point falls on land. In a country or state lets you pick a country and, if you like, one of its states, provinces or regions. Near me draws points within a radius of where you are. Random town picks a real town, filterable by country, state and population.
- Set how many points. The default is 1; the maximum is 100 per batch. For travel-planning style use cases (one random destination), 1 is right; for dataset seeding or geocaching challenges, 5–25 is typical; for stress-testing and analysis, go up to 100.
- Optionally set a seed. A seed makes the result reproducible: the same seed + same settings always produce the same points. Useful for sharing ("here are the 5 random spots, seed = trip-2026"), for testing, or for repeatable runs in research and education. Leave the seed empty for true Math.random output.
- Generate. Tap the green Generate button. Pins drop on the map, the coordinates list fills in, and the map auto-frames every pin. A single point opens its place card right away.
- Select a point to open its place card. Tap any pin or any row in the coordinates list. The card shows the country and region, the nearest towns with distance and direction, elevation or ocean depth, the local time and whether it is day or night, today’s sunrise and sunset, a Wikipedia-nearby button, and links to open the point in Google Maps, Street View and OpenStreetMap. Details load only for the point you select, so a batch of 100 stays fast.
- Re-roll, copy, or export. Tap "Re-roll" for another batch with the same settings (a fresh internal seed). Copy the whole list of coordinates in decimal or DMS, copy or share any single point by link, or export the batch as CSV or GeoJSON.
The modes — and when to use each
| Mode | What it does | Land vs ocean | Best for |
|---|---|---|---|
| Anywhere on the sphere | Uniformly distributed point anywhere on Earth — ocean, ice cap, populated land, all weighted by surface area. | ~71% in ocean, ~29% on land | Pure mathematical curiosity, math-class demos, surface-distribution visualisation. |
| Land only | Re-rolls until the point falls inside a country polygon (Natural Earth 1:50m / 1:50,000,000-scale). Ocean, sea, and small unmapped islands are skipped. | 0% (ocean rejected) | Travel inspiration, geography quizzes, picking a random place on terra firma. |
| In a country or state | Generates points only inside a chosen country’s polygon. Use the 🎲 button for a random country pick. | 0% (area interior only) | Marketing geofences, geocaching within a region, education focused on one country or state. |
| Near me | Points within a radius of your location (area-uniform inside the circle), optionally land-only. Your location stays in your browser. | Land-only by default | Nearby day trips, local scavenger hunts, testing something close to home. |
| Random town | A real town chosen at random, filterable by country, state and minimum population. Every matching town is equally likely. | Always a populated place | Travel picks, classroom geography, a random city for a prompt. |
What people use this tool for
Six common jobs, and the card field or option that does the work in each.
Travel ideas — "where should I go next?"
Pick "Land only" with count = 1 and generate. The place card names the country and region and lists the nearest towns with distance and direction, so a bare coordinate becomes a real destination you can picture. Street View (nearest panorama) and the Wikipedia-nearby button tell you what is actually there. Honest inspiration — more varied than a curated "best of" list.
Geography games
Generate 5 random countries with the 🎲 button, or drop 20 random points on land and have players name each country and guess what is nearby. The card hides nothing: the country flag, admin region, continent and nearest towns all become the answer key. Equal-area sampling means Russia, Canada, China, the USA and Brazil come up most, tiny states rarely — geography in proportion to real land area.
Exploring somewhere new
Treat one random point as a doorway. The card’s landform line ("Colorado Plateau", "Sahara"), the elevation or ocean depth, and the day-or-night and sunrise/sunset fields sketch the place before you ever open a map. The "Open in" links jump straight to Google Maps, Street View and OpenStreetMap; the night-side toggle on the map shows whether it is light there now.
Test data for apps and maps
Seed test data with a reproducible batch — the same seed and settings always return the same points, so CI runs don’t flake. Points are equal-area uniform, antimeridian-safe and validated against country polygons. Export CSV (id, lat, lng, country, ISO 2) or GeoJSON that drops straight into QGIS, Mapbox or Leaflet. The coordinates list copies in decimal or DMS in one click.
Teaching latitude and longitude
Generate a point and switch the coordinates list between decimal degrees and DMS to show the two notations side by side. The card’s nearest-town distances (in km and miles with a compass direction) make bearings concrete, and the day/night plus sunrise/sunset fields connect longitude to local time. The "Explore this point" links open the same coordinate in the elevation and time-zone tools.
Writing prompts
Roll a random place and let the card set the scene: a country and region, the nearest town, whether it is day or night right now, and the landform it sits in. Writers and worldbuilders use the seed to keep a prompt reproducible — the same seed re-creates the same place list — and the Wikipedia-nearby button turns a coordinate into real detail to research.
How the tool actually works
1. Sphere sampling
Two uniform random numbers u, v ∈ [0, 1]. Latitude: lat = asin(2u − 1) × 180/π (range -90° to +90°, weighted equal-area). Longitude: lng = -180 + v × 360 (uniform). The math is one of the standard Marsaglia methods for sphere-uniform sampling.
2. Land-only filter (rejection sampling)
Generate a sphere-uniform point. Run a point-in-polygon test against all 241 country features in Natural Earth’s 1:50,000,000 cultural-vectors set. If the point falls inside a country polygon, accept it. If not (ocean / unmapped), retry up to 250 times. Empirically the first attempt succeeds ~29% of the time, so the average count of attempts for a single accepted point is about 3.4. Even at 100 batch size, total runtime is well under a second.
3. In-a-country sampling
Compute the bounding box of the country polygon (minimum and maximum lat/lng). Sample a point inside the bounding box using the same equal-area latitude transform within the latitude band. If the point falls inside the country polygon, accept; otherwise reject and retry up to 600 times. For most countries, 1–3 attempts succeed; for awkwardly shaped countries (Chile, Norway, Indonesia), 5–15 is typical.
4. Pseudorandom number generation
With no seed: native Math.random() (different on every page-load). With a seed: we hash the seed string with the 53-bit cyrb53 hash, then feed the result into mulberry32 — a small, statistically robust 32-bit PRNG. Same seed + same settings = same points, every time. Different seeds produce statistically independent point sets.
5. The place card (loaded on selection)
Details load only for the point you select, never for a whole batch, so a run of 100 points stays fast. When you pick a point, the card calls our own place lookup — a compact build of Natural Earth admin-1, marine and landform polygons plus GeoNames towns, served from the site — to name the country and region, the sea for an ocean point, the landform, the continent, and the nearest towns by distance and direction. Elevation (or ocean depth) comes from AWS Terrain Tiles; the time zone from the same lookup the Time Zone Finder uses; day/night and today’s sunrise and sunset from Astronomy Engine. The Wikipedia-nearby search runs only when you tap its button.
6. Near me (points around you)
Pick an angular distance whose cosine is spread evenly from the center out to the chosen radius — this is what makes every ring of the circle get its fair share of area, instead of crowding the middle — and a uniform compass bearing, then step that far along the great circle from where you are. With “Land only” on, a point that falls on water is re-rolled until it lands on land. Your location stays in your browser; nothing about it is sent anywhere, and only a point you open is looked up for its details.
7. States, provinces and regions
To draw inside one first-level area fairly, each separate piece of the area is weighted by its true surface area; a piece is chosen in proportion to that weight, a point is drawn uniformly by area inside its bounding box, and it is kept only if it falls within the area’s actual shape (holes excluded). Because the point is drawn in the same shape the card reads from, a point drawn in Texas is labeled Texas.
8. Random town
Every town that matches your filters — country, state or province, and minimum population — is equally likely, and a batch never repeats one. The towns come from the free GeoNames dataset (CC BY 4.0), 171,161 populated places in all, so the picks cluster where towns are dense rather than spreading evenly across the map.
SimpleMapLab vs other random location generators
Honest comparison with the major free random location tools online. Each tool wins different scenarios.
The pole bias bug — why most random location tools are wrong
You can see the bug for yourself: take any generator that picks a latitude uniformly between -90° and +90°, generate a few thousand points, and plot them on a globe. They pile up in two visible blobs at the North and South Poles, with the equatorial belt looking suspiciously empty — the signature of sampling latitude instead of sin(latitude).
The math reason: if you pick latitude uniformly, the probability of being in the latitude band [70°, 80°] is the same as [0°, 10°] — namely 1/18. But polar latitude bands are weighted by cos(latitude), so the surface area of [70°, 80°] is dramatically smaller than [0°, 10°]. The same number of points are squeezed into much less area near the pole — much higher density.
Visually: a "random place on Earth" produced by a naive generator overrepresents high-latitude countries (Russia is the closest to the pole and the most over-counted) versus their actual surface area share. Antarctica is wildly overrepresented. The Pacific Ocean is underrepresented because most of it is near the equator.
Our fix is the asin(2u − 1) transformation. After this transformation, a random point is genuinely uniform over the sphere’s surface area — Russia comes up in proportion to its actual share, the equator gets its fair turn, and the South Pacific is honestly represented.
Which country comes up most often in "Land only" mode?
For a uniformly distributed point on land, the probability of any country is its share of the total land area. The biggest land areas (and their approximate land-area share):
- Russia — 17.1 million km² (≈11.4% of all land)
- Antarctica — 14.0 million km² (≈9.4%, but excluded from most "country" lookups since it is governed by treaty, not as a country)
- Canada — 9.98 million km² (≈6.7%)
- USA — 9.83 million km² (≈6.6%)
- China — 9.60 million km² (≈6.4%)
- Brazil — 8.51 million km² (≈5.7%)
- Australia — 7.69 million km² (≈5.1%)
- India — 3.29 million km² (≈2.2%)
- Argentina — 2.78 million km² (≈1.9%)
- Kazakhstan — 2.72 million km² (≈1.8%)
Generate 100 land-only points, and on average ~50 will fall in those top ten countries. The remaining ~50 are spread across the other 185 countries. Vatican City (0.49 km²) has a 0.0000003% chance per random pick — you would need to generate ~300 million points before one lands inside it.
Related tools and resources
For a single point picked by area or population: Find Cities in Radius and Find ZIP Codes in Radius. For the country at any GPS point: What Country Am I In?. For elevation at a random point: Elevation Finder. For time zone at a random point: Time Zone Finder. For drawing distance circles around a random pick: Map Radius Tool. For the antipode of a random point: Antipode Finder. For coloring a map with a random country pick: Color a Map.
Frequently asked questions
Sphere sampling: equal-area transform lat = asin(2u − 1), lng = -180 + v × 360, with cyrb53 + mulberry32 pseudorandom generation (non-cryptographic). Land filter: ray-casting point-in-polygon against Natural Earth 1:50m country boundaries (public domain). Place card: country, admin-1 region, sea, landform and continent from Natural Earth 10m administrative, marine and physical polygons (public domain, simplified); nearest towns from GeoNames (CC BY 4.0). Elevation and ocean depth: AWS Terrain Tiles (USGS 3DEP, SRTM, GEBCO/ETOPO). Time zone: the IANA time zone database via the same lookup used by our Time Zone Finder. Day/night, sunrise and sunset: Astronomy Engine. Nearby places: Wikipedia GeoSearch (links only, fetched when you tap the button). Map basemap: OpenFreeMap Liberty vector tiles. The anywhere, land-only, whole-country and Near me draws run entirely in your browser; the state, province and random-town draws are answered by the site, which holds their larger datasets. Your own location never leaves your browser, and a point’s coordinates leave the page only when you open it, to fetch its place details, time zone and Wikipedia results. Exports are built in your browser as file downloads.
More SimpleMapLab tools
Identify the country at any GPS, address, or map click.
Find the exact opposite side of the Earth from any location.
Compass bearing between two points — true and magnetic.
Find altitude of any point on Earth from a random GPS pick.