GenerateRandomSearch

Geohash Converter

A geohash is built by repeatedly halving the world — east or west, north or south — and writing the answers down. That construction gives it a property databases love: two places close together usually share a prefix, so a range query on the string finds neighbours without any geometry at all. Usually, not always — the halving means places either side of a boundary can differ from the first character.

What this generator does

Encodes coordinates into a geohash of the length you choose, decodes it back into the rectangle it names, and reports the corners and the size of that rectangle.

How to use this tool

  1. Enter a latitude and longitude.
  2. Choose how many characters you want.
  3. Read the hash and the box it names.
  4. Try a nearby point and compare how much of the prefix matches.

Understanding the controls

Latitude and longitude
In decimal degrees, with south and west written as negative numbers.
How many characters
One to twelve. Five is roughly a town, seven a neighbourhood, nine a street address, and beyond that finer than most uses need.

Common use cases

  • Indexing locations in a database that has no spatial support
  • Bucketing points into tiles for aggregation
  • Understanding what precision a given hash length gives you
  • Checking a geohash against the coordinates it should describe
  • Explaining why prefix matching finds neighbours but not reliably

How this generator works

The point given must lie inside the box the hash decodes to, and re-encoding that box's centre must return the same hash — both are checked before the answer appears. The alphabet deliberately leaves out a, i, l and o, so a hash cannot be misread as a word or confused with a digit.

Randomness and fairness

Nothing is random. The same coordinates and length always give the same hash.

For how randomness is produced across the whole site, see how Generate Random works.

Limitations and good to know

  • Coordinates in, hash out; decoding a hash you already have is not offered here.
  • Prefix sharing is a useful habit rather than a guarantee — two places metres apart can sit either side of a fold and share nothing.
  • Boxes are not square: they alternate between wide and tall as the length grows.
  • A geohash cell is not square: it is wider than it is tall near the equator and the reverse towards the poles, so the metres quoted are a guide rather than a measurement.

Privacy and your data

Everything is computed in your browser. No location is transmitted or stored.