Online GeoJSON Validator
Check your GeoJSON for errors online
Paste a GeoJSON object or upload a .geojson or .json file. The validator lists every problem and shows exactly where in the document it occurs.
Check GeoJSON syntax and structure
A JSON parser checks whether text follows JSON syntax. GeoJSON validation goes further: the JSON must also describe a recognized GeoJSON object with the members and coordinate structure expected for its geometry.
For example, {"type": "Point", "coordinates": [12.5, 55.7]}
is valid JSON and has the basic shape of a GeoJSON Point. A trailing
comma such as {"type": "Point",} is invalid JSON and cannot
be parsed. A JSON object missing required GeoJSON members may parse
successfully but still fail structural validation.
Example input and output
Paste this GeoJSON Feature and select Validate:
{"type":"Feature","properties":{"name":"Copenhagen"},"geometry":{"type":"Point","coordinates":[12.5,55.7]}}
Result:
Valid GeoJSON
A valid document has no error messages in the result list.
Geometry types and coordinate order
GeoJSON geometry objects use one of these standard types:
Point, MultiPoint, LineString,
MultiLineString, Polygon,
MultiPolygon or GeometryCollection. A position
is written as longitude, latitude (and optionally altitude), not
latitude first. For example, San Francisco is approximately
[-122.4194, 37.7749].
How to validate a GeoJSON document
- Paste the document or upload a
.jsonor.geojsonfile. - Select Validate and read whether the document is valid.
- For invalid input, use the returned error messages and paths to locate the syntax or structure problem, then correct the source.
Common problems to check
- JSON punctuation errors, including missing quotes, brackets or commas.
- Missing or misspelled required members such as
type,coordinatesorgeometry. - Coordinates entered as latitude, longitude instead of GeoJSON's longitude, latitude order.
- Polygon rings that are not closed or coordinate arrays with the wrong nesting.
Continue working with your data
For viewing, conversion and bounding boxes, see the GeoJSON and GIS data tools. For examples of each kind of error, see how to fix invalid GeoJSON.
Business applications
Validate geographic documents before importing them into a mapping, transportation or logistics application. Structural validation can detect malformed GeoJSON, but it does not confirm that coordinates are accurate or that features meet an application's business rules.
Frequently asked questions
What does the GeoJSON validator check?
It checks that your document is valid GeoJSON: the object type, required members such as coordinates and geometry, the shape of coordinate arrays and polygon rings. Each problem is reported with the path to where it occurs.
Which GeoJSON types are supported?
The validator accepts GeoJSON objects and reports validation errors. The public API reference does not enumerate geometry-specific restrictions, so check its current schema if your data uses a less common geometry or extension.
Why is my GeoJSON invalid?
Common causes are swapped longitude and latitude, polygon rings that are not closed, missing required members such as type or coordinates, and trailing commas or other JSON syntax errors.
Does GeoJSON use latitude first or longitude first?
GeoJSON positions are written as [longitude, latitude], with longitude first. Many tools and people use latitude first, which is a frequent source of errors.
Can I validate GeoJSON from my own code?
Yes. The validator is part of our API, so you can validate GeoJSON automatically in your own application or pipeline.
What is the difference between a JSON error and a GeoJSON error?
A JSON syntax error means the text cannot be parsed as JSON. A GeoJSON validation error means the JSON parsed but does not satisfy the GeoJSON structure or geometry rules expected by the validator.
Which coordinate order does GeoJSON use?
GeoJSON coordinates are longitude first, then latitude. For example, San Francisco is approximately [-122.4194, 37.7749].
Use this capability in your application
Validate GeoJSON from an application or data pipeline with the GeoJSON validation operation in the Geospatial Toolbox API.