H3
Uber's H3 hexagonal grid.
H3 is Uber's hexagonal grid: 16 resolutions, each cell about one seventh the area of its parent, with 12 pentagons at every resolution. These tools index points, inspect cells, walk the hierarchy, search rings and paths, fill polygons, and outline sets of cells. Analysts and developers use H3 to aggregate points, join datasets, and search neighborhoods. Start with the resolution chooser to pick a cell size, then the point-to-cell tool. Pitfall: near a pentagon a cell has five neighbors, not six, so code that expects fixed ring sizes can break.
No tools here match . or .
I want to find the H3 cell for a point, or inspect a cell
- H3 cell for a point
The H3 cell containing a latitude and longitude at resolution 0 to 15 (latLngToCell), with the cell's center and area.
- H3 cell inspector
Everything about an H3 cell: center (cellToLatLng), boundary (cellToBoundary), resolution, base cell, pentagon and Class III checks, area, and decimal form.
- H3 edges and vertexes
The directed edges (with lengths and neighbors) and vertexes of an H3 cell (originToDirectedEdges, cellToVertexes).
I want to choose a resolution
- H3 resolution chooser
The H3 resolution whose average cell is closest to a target area or edge length, with the full resolution table (122 base cells, 12 pentagons at each resolution).
I want to move up or down the hierarchy
- H3 parent cell
The coarser H3 cell that contains a cell (cellToParent), and the cell's position among that parent's children.
- H3 children cells
The finer H3 cells inside a cell (cellToChildren), their count, and the center child.
- H3 compact
Replaces every complete group of 7 sibling cells with their parent, repeatedly, for the smallest set covering the same area (compactCells).
- H3 uncompact
Expands a mixed-resolution set of H3 cells to one resolution (uncompactCells).
I want to find cells around or between cells
- H3 grid disk (k-ring)
All H3 cells within k steps of a cell (gridDisk); fewer than 3k(k+1)+1 when a pentagon is nearby.
- H3 grid ring
The H3 cells exactly k steps from a cell (gridRing), the hollow ring.
- H3 grid path and distance
The grid distance between two H3 cells (gridDistance) and the line of cells joining them (gridPathCells).
I want to do grid arithmetic around an origin cell
- H3 local IJ for a cell (cellToLocalIj)
The local IJ coordinates of a cell as seen from an origin cell: two whole numbers on the grid H3 unfolds around that origin.
- H3 cell at local IJ (localIjToCell)
The H3 cell at local IJ coordinates around an origin cell, undoing cellToLocalIj.
I want to fill a polygon with cells
- H3 polygon fill (polygonToCells)
The H3 cells that fill a polygon (with holes, across the antimeridian) at a resolution, by an explicit containment mode: cell centers inside, whole cells inside, or any overlap.
I want to outline a set of cells as a polygon
- H3 cell set outline (cellsToMultiPolygon)
The outline of a set of H3 cells: the boundary between the set and everything outside it, as polygons with their holes, in GeoJSON.
Guides that use these tools
- Developer: index to area: Choose an H3 resolution for the cell size you want, index a point, inspect its cell and neighbors, and fill an area.