I built WhereMatch, a free web tool that estimates where a photo was taken from what is visible in it. It is a Next.js app that calls the Claude API. Before telling anyone it works, I wanted a number, so I ran a test and published the answers. This is how I did it, what came out, and what I got wrong.
This post was drafted with AI assistance and checked against the published test results.
This is my own test, not an independent one. The caveats matter more than the headline, so they come with the numbers.
Method
- I wrote a list of places first: famous landmarks, streets in large cities, small towns, and landscapes, spread over the inhabited continents.
- For each place a script took the first suitable geotagged photo within a short distance on Wikimedia Commons. I did not pick photos by hand.
- Before running anything I looked through them and removed 22 that were mainly interiors, signs, portraits or close-ups, since the tool is not meant for those. I removed none after seeing an answer.
- That left 110 photos. Each was sent once with location data stripped, and I kept the first answer.
- Distance is measured from the answer to the geotag stored on Commons, which is normally where the photographer stood.
Results
Median distance across all 110 photos was 110 m.
| Kind | Photos | Median | Within 1 km |
|---|---|---|---|
| Famous landmarks | 20 | 10 m | 85% |
| City streets | 42 | 60 m | 95% |
| Small towns | 19 | 70 m | 100% |
| Landscapes | 29 | 650 m | 62% |
| All | 110 | 110 m | 85% |
Overall, 96% were within 25 km and 99% within 200 km. The tool also states a radius with each answer. The true spot was inside its own radius for 101 of 110 photos, so the radius is a reasonable hint, though not a guarantee.
The caveats, in full
I would not quote the table without these.
- The places were picked by me and lean famous. Real-world photos are less kind.
- When the model is unsure, it names the best-known spot in the region. In this test, that is often where the photo came from. A photo from somewhere obscure gets no such help, so real-world results will be worse than these figures.
- The photos are public, and the model may have seen them or others from the same spot.
- A geotag can be off, or mark the subject rather than the camera. For distant mountains the two can be kilometres apart.
- It is one run. The same photo can get a different answer another time.
- I wrote and ran the test myself. Nobody has checked it.
Landscapes were the weak spot, as I expected. A mountain with no signs, roads or buildings is a hard problem, and the numbers show it.
The worst miss was a typo
The single largest error was not a wrong guess. The model named the Taj Mahal correctly, then wrote latitude 7.17 instead of 27.17. The pin landed in the sea off Sri Lanka, 2,224 km from the real spot. The reasoning was right and the number was wrong, and from the user's side that is the same as being wrong.
The fix is cheap. Every answer includes a country. I keep an outline of each country (Natural Earth data) and check whether the coordinates fall inside the outline of the country the answer names. If they do not, I ask the model once more, in plain text with no image, for the coordinates of the named place, and use that if it fits.
A simplified version of the idea, written fresh for this article:
type Answer = { place: string; country: string; lat: number; lon: number }; async function checkedAnswer(a: Answer): Promise<Answer> { if (insideCountry(a.lat, a.lon, a.country)) return a; // One retry, text only: just the coordinates of the place it already named. const [lat, lon] = await askForCoordinates(`${a.place}, ${a.country}`); // Only accept the second answer if it passes the same check. if (insideCountry(lat, lon, a.country)) return { ...a, lat, lon }; return a; // still flagged as unverified downstream } Details that mattered in practice: the outlines are coarse and photos get taken on piers, coasts and boats, so a point slightly outside a border should still pass. I allow a small margin. If the country is unknown, the check says nothing instead of failing the answer. And the numbers in the table are from before this fix, so the Taj Mahal miss is still in them.
This kind of check is general. If an LLM returns structured data with an internal redundancy, such as a country and a coordinate, you can test them against each other.
Prompt changes did not help
After the main test I built a second, harder set of 40 photos from little-known towns, and used it to try changes to the prompt:
- a longer "method" prompt describing how to reason about clues
- more reasoning effort
- taking the middle of three answers
- letting the model search the web
None beat the run-to-run noise of the unchanged prompt. Two runs of the same prompt differed from each other as much as the variants did. With 40 photos, any difference I could see was inside that spread, so I kept the simple prompt. I cannot say these ideas never help, only that I could not measure a benefit on this set. A bigger test might show something I missed.
That was the most useful thing I learned about evaluation: run the baseline twice before comparing anything to it.
What I would do next
Test on photos nobody has published, and have someone else pick them. That removes the first three caveats at once, and I expect the results to be worse. Until then, treat my numbers as an upper bound.
WhereMatch is free during testing, five photos a day, no account. The full results and every answer are at https://wherematch.com/accuracy and https://wherematch.com/examples.