Random places on Earth, picked fairly
This random location generator picks points on the map for you. Press Generate and a marker drops somewhere on the planet: in a desert, on a mountain, in a small town you have never heard of. Each point comes with its exact latitude and longitude, the country it is in, and buttons that open the spot in Google Maps or Street View. You can make one point at a time, or use it for bulk lat long generation: up to 1,000 random coordinates in one click, ready to download.
You decide where the points may fall. "On land" keeps every point on dry land. "Anywhere" uses the whole globe, so most points land in the ocean, just like a real dart thrown at a globe. "In a country" keeps the points inside one of 242 countries and territories: type the name to find it, or let the dice button pick a random country. "Near a point" is a random lat long generator inside a circle around any spot you click, for example within 50 km of your home. "In a box" works as a geographic points generator inside a bounding box that you draw on the map or type as four edges. "In my shapes" places random lat lon points inside a shapefile boundary or any other polygons from your own file, such as a park, a city district or a sales region.
The important part is that the points are fair. Many tools that make random geographic coordinates simply pick a random latitude between −90 and 90, which puts far too many points near the North and South Poles. This tool spreads the points by area, so every square kilometre has the same chance. My tip: for a "where in the world am I?" game with friends, use "On land", generate one point, and open it in Street View before anyone looks at the map.
Six ways to choose where the points fall
The buttons at the top of the tool set the area. Each mode spreads the points evenly inside its area.
- On land. Points fall only on land, from Greenland to Patagonia. Bigger countries get more points, because they cover more ground. Antarctica is left out by default; tick "Include Antarctica" to add it.
- Anywhere. Points fall anywhere on the sphere, land or sea. About 29 of every 100 points land on land, which matches the real share of land on Earth. Points at sea are marked "At sea" in blue.
- In a country. Type a few letters of a country name and pick it from the list. The search knows 242 countries and territories, in the language of this page and in English, and it ignores accents and capital letters, so "curacao" finds Curaçao and "JP" finds Japan. Press "Random country" to let the tool choose one of the 195 countries of the world for you and fill it with points.
- Near a point. Click the map to set the centre of a circle, or press "My location". Set the radius in kilometres (up to 20,000 km), and the tool fills the circle with random lat long points, spread evenly over its area. Tick "Land only" to skip points that fall in a lake or the sea.
- In a box. Limit the points to a bounding box: click two opposite corners on the map to draw it, or type its four edges (West, South, East, North) in decimal degrees. The tool shows the area of the box in km². A box whose West edge is east of its East edge crosses the 180° line, for example West 170 and East −170 around Fiji. "Land only" works here too.
- In my shapes. Fill your own area with random points: upload a file with one or more polygons, as GeoJSON, KML, KMZ, a zipped Shapefile or WKT, up to 50 MB. You can also drop the file onto the map. The points are spread over all the polygons by area, holes stay empty, and lines and points in the file are ignored. The file is read in your browser and never uploaded to a server.
In every mode, "Points" sets how many locations you get, from 1 to 1,000. Press Enter in that box or click Generate.
How to generate random locations, step by step
Here is the whole process, from an empty map to a file of random coordinates.

The world map opens with the "On land" mode selected and one point set in the "Points" box. The panel on the right is still empty.

Press Generate. The map moves to the new point and opens its popup with the coordinates in decimal degrees and in degrees, minutes and seconds, the country, and the Google Maps and Street View buttons.

Type 200 in the "Points" box and press Generate. The points cover the land evenly, and the list on the right shows each one with its country.

Choose "In a country", type the first letters of a country (here "jap") and pick it from the list, then generate. Or press "Random country" and let the dice decide.

Choose "Near a point", click the map to set the centre and set the radius. Here 30 points fall within 50 km of Paris, inside the circle drawn on the map.

Choose "In a box" and click two corners on the map, or type the four edges. Here the geographic points generator puts 50 points inside a bounding box around the Alps. With "In my shapes" you upload your own polygons instead.

Click a point in the list to show it on the map, press SV to open it in Street View, copy all coordinates, copy a share link, or download the points as CSV, GeoJSON or KML.
What you can do with the points
Every point is ready to use in other apps. These are the options in the results panel and in each popup.
- Google Maps and Street View. Each popup has a Google Maps button and a Street View button. Street View opens the nearest street-level photo, if Google has one close to the point.
- Two coordinate formats. The popup shows decimal degrees with 6 decimals (about 0.1 m) and degrees, minutes and seconds, for example
48°51′23.8″ N. The Copy button copies the decimal version. - Copy all. Copies every point as one "latitude, longitude" line, ready to paste into a spreadsheet, a chat or another map tool.
- Share link. Copies a link that opens this tool with the same points on the map, so a friend sees exactly what you see. The link holds up to 100 points.
- CSV, GeoJSON and KML. For bulk lat long generation, the downloads hold every point, up to 1,000. CSV opens in Excel or Google Sheets, with the columns
id,latitude,longitude,countryandcountry_code. GeoJSON works in QGIS and web maps. KML opens in Google Earth.
How the tool picks fair random coordinates
Getting random geographic coordinates that are truly even over a round Earth takes a little care. Here is the method behind each mode, with real numbers.
Why a random latitude is not enough
A band of 1° of latitude near the equator is a wide belt around the whole planet. A band of 1° next to a pole is a tiny cap. So if you pick latitude evenly between −90° and 90°, the small polar areas get the same number of points as the huge tropical belt. The share of the Earth between two latitudes a and b is (sin b − sin a) / 2:
Area north of 80° N: (sin 90° − sin 80°) / 2
= (1 − 0.98481) / 2
= 0.0076 → 0.76 % of the Earth
Naive method: 10° out of 180° → 5.56 % of the points
5.56 / 0.76 ≈ 7.3 times too many points near the poleIn a test with 20,000 points from this tool, 0.76 % fell north of 80° N, exactly the right share.
Anywhere: an even spread over the sphere
The fix is to pick the sine of the latitude evenly, not the latitude itself. With two random numbers u and v between 0 and 1:
latitude = asin(2u − 1) longitude = 360 × v − 180 Example: u = 0.75 → asin(0.5) = 30° N A quarter of all points are north of 30° N, and a quarter of the Earth's surface is north of 30° N.
In the same test, 28.7 % of the points fell on land, close to the 29 % of the Earth that is land.
On land and in a country: weighted by area
The country outlines are made of 1,620 separate shapes: mainlands, islands and exclaves. The tool measures the area of each shape on the sphere. To place a point, it first picks a shape, with the chance in proportion to its area, then picks a point inside that shape with the same sine-of-latitude rule, and keeps it only if it really lies inside the outline. This is called rejection sampling.
Russia's shapes: 12.56 % of the land (without Antarctica) Test, 20,000 points on land: 12.52 % fell in Russia Brazil: 6.33 % of the land → 6.32 % of the points India: 2.35 % of the land → 2.31 % of the points
Because each island is its own shape, small countries spread over many islands, like Fiji, which crosses the 180° line, work just as well as large ones.
Near a point: an even spread inside a circle
For a circle around a centre, the tool picks the distance and the direction separately. The direction is any angle from 0° to 360°. The distance is not picked evenly, because the outer rings of a circle are bigger than the inner ones. On the sphere, the angular distance θ follows this rule, where θmax is the radius divided by the Earth's radius of 6,371 km:
cos θ = 1 − u × (1 − cos θmax) Radius 100 km: θmax = 100 / 6,371 = 0.0157 rad Average distance of the points from the centre: expected ≈ 2/3 × 100 km = 66.7 km test with 5,000 points: 66.4 km
The point itself is found with the standard destination formula, the same one navigation apps use to go a given distance in a given direction. This works for any radius, even one that covers half the globe.
In a box and in your shapes
A box uses the same sine rule as "Anywhere", only between its own edges: the sine of the latitude is picked evenly between the South and North edges, and the longitude evenly from West to East. The area of a box follows from the same idea:
area = (sin North − sin South) × (East − West in radians) × 6,371² Box 0° to 1° N, 0° to 1° E: (0.017452 − 0) × 0.017453 × 6,371² ≈ 12,364 km² Test, box 0° to 80° N: 34.7 % of the points north of 40° N expected (sin 80° − sin 40°) / sin 80° = 34.7 %
Your own polygons are treated exactly like the country shapes: each polygon is weighted by its area, and rejection sampling keeps the points inside the outline and out of the holes. In a test with two shapes, a 2° × 2° square with a 1° × 1° hole and a separate 1° × 1° square, the small square got 24.8 % of the points (expected about 25 %) and the hole got none.
8 ways people use random coordinates
A random point on the map sounds like a toy, but it is useful in many places.
- Geography guessing games. Generate a point on land, open it in Street View and try to guess the country before you look at the map. It works like GeoGuessr, for free, with any group of friends.
- A random travel destination. Cannot decide where to go next? Let the tool pick a random place in the world, or a point in your own country or within a day's drive of home, and plan a trip to the nearest town.
- Teaching geography. Teachers generate a point, and the class finds out what country, climate zone and landscape it is in. "In a country" makes a good quiz about one region.
- Writing and art prompts. Writers set a story in a random place. Artists and photographers use Street View at a random spot as a prompt for a drawing or a virtual photo walk.
- Test data for software. Developers need realistic coordinates to test maps, apps and databases. Bulk lat long generation gives them 1,000 points as CSV or GeoJSON in one click, with the country code already in the file.
- Random sampling for field work. Ecologists and survey teams pick random sample sites inside a study area, so the result is not biased by where it is easy to walk. Upload the study area as a Shapefile to get sites inside its boundary, or use "Near a point" for sites within a set distance of a base camp.
- A random country challenge. Press "Random country" and cook a dish, listen to music or read a book from that country. The dice picks from the 195 countries of the world, not from territories.
- Virtual exploring. Some people just like to see the world. Generate a point, open Street View, and visit a place you would never find on your own.
Frequently asked questions
Twelve questions people often ask about random locations, with direct answers.
1. How does the random location generator work?
You choose an area (on land, anywhere, a country, a circle around a point, a bounding box or your own polygons) and how many points you want, then press Generate. For a single random place in the world, keep "Points" at 1. The tool picks the points in your browser, spread evenly by area, and shows them on the map with their coordinates and country.
2. Are the locations really random?
They come from your browser's random number generator, which is more than random enough for games, teaching, travel ideas and test data. It is not meant for security or lotteries. If you need the same points again later, for example for a study, download them as CSV, because pressing Generate again gives new points.
3. Why don't the points bunch up near the poles?
Because the tool picks the sine of the latitude evenly, not the latitude. Picking latitude evenly puts about 7 times too many points north of 80° N. The section on the math above shows the numbers.
4. Can I get random coordinates only on land?
Yes. "On land" places every point on land, weighted by area, and leaves out Antarctica unless you tick "Include Antarctica". In "Near a point", tick "Land only" to skip points in the sea and in large lakes.
5. Can I generate a random location in a specific country?
Yes. Choose "In a country" and pick one of 242 countries and territories. The points are spread over the whole country, including its islands. "Random country" picks one of the 195 countries of the world for you: the 193 member states of the United Nations, plus Vatican City and Palestine.
6. Can I generate random points inside a bounding box?
Yes, the tool is also a geographic points generator inside a bounding box. Choose "In a box", then click two opposite corners on the map or type the West, South, East and North edges in decimal degrees, for example West 5.9, South 45.8, East 10.5, North 47.8 for Switzerland's box. The points are spread evenly by area inside the box. Tick "Land only" to keep them out of lakes and the sea.
7. Can I generate random lat lon points inside a shapefile boundary?
Yes, and inside any other area of your own, like a park or a sales region. Choose "In my shapes" and upload a GeoJSON, KML, KMZ, zipped Shapefile or WKT file with one or more polygons. A Shapefile in another coordinate system works if its .prj file is in the ZIP. The points are spread over all the polygons by area, and the file never leaves your browser.
8. Can I generate random coordinates in bulk?
Yes, up to 1,000 at once: type the number in "Points" and press Generate. All of them appear on the map and in the CSV, GeoJSON and KML downloads. The list in the panel shows the first 200, and a share link holds the first 100.
9. Why does Street View sometimes show nothing?
Street View only has photos along roads and at some places Google has visited. A random point in a forest, a desert or a country with little coverage may have no photo nearby. Generate a new point, or choose "In a country" with a country that has good coverage.
10. What coordinate format does the tool use?
Latitude and longitude in WGS 84 (the system GPS uses), in decimal degrees with 6 decimals, which is about 0.1 m. The popup also shows degrees, minutes and seconds. Positive latitude is north and positive longitude is east.
11. How exact are the country borders?
The outlines come from Natural Earth at a scale of 1:50 million. They are accurate to a few kilometres, so a point very close to a border or coast may be named after the neighbouring country, or counted as land when it is just off the shore. Disputed areas follow Natural Earth.
12. Is anything I do sent to a server?
No. The points are made in your browser, and the country outlines are loaded once from this site. Only the map tiles come from a map server, as on any online map. A share link contains the points themselves, so anyone with the link sees them.
Data, libraries and credits
This tool is built on open data and open source software. Many thanks to the people behind these projects.
- Natural Earth (1:50m Admin 0 countries) · Public domainThe country outlines for "On land" and "In a country", and the country name of every point.
- Leaflet 1.9 · BSD-2-ClauseDraws the interactive map, the points, the popups and the circle.
- Protomaps (hosted by KONAKTIVE), CARTO, OpenStreetMap · ODbL data, provider termsThe street basemap: our own vector tiles from OpenStreetMap data, with CARTO and OpenStreetMap tiles as backups.
- Esri World Imagery · Provider termsThe satellite basemap.
- Turf.js (@turf/area) · MITMeasures the area of every country shape on the sphere, so that larger areas get more points.
- Read the files you upload for "In my shapes": zipped Shapefiles, KML and KMZ, and WKT.
- Google Maps URLs · Link format onlyThe Google Maps and Street View buttons open these public link formats.
Nothing you generate is stored or sent anywhere. The country outlines are public domain.
Related tools
Borders are simplified and do not take a position on disputed territories. Country outlines: Natural Earth (public domain).
Map tiles © OpenStreetMap contributors, drawn with Protomaps (hosted by KONAKTIVE), with CARTO as the fallback.
