Validate GeoJSON against RFC 7946 in your browser
This tool checks a GeoJSON document against the structural rules of RFC 7946, the specification that defines GeoJSON. It catches the mistakes that silently break maps — out-of-range coordinates, unclosed polygon rings, too-few points — and tells you exactly which feature is at fault. It is built for developers wiring up Leaflet, Mapbox or a spatial database.
How it works
The tool first parses the text as JSON. It then walks the document by type:
- FeatureCollection must have a
featuresarray; each entry is validated as a Feature. - Feature must carry a
geometryand apropertiesmember (object ornull). - Geometry is checked per type — every position needs at least two numbers with
longitude in
[-180, 180]and latitude in[-90, 90];LineStringneeds 2+ positions; eachPolygonring needs 4+ positions and must be closed (first position equals last).
Polygon winding order (exterior counter-clockwise, holes clockwise per the right-hand rule) is reported as a warning, since RFC 7946 requires parsers to accept either order.
Notes
Everything is computed locally — nothing is uploaded. Errors name the feature index and the rule that failed so you can jump straight to the problem.