JSON Forge
100% Client-Side: your data is never sent to a server

JSON examples

GeoJSON Example

GeoJSON is JSON for geographic data. This example is a FeatureCollection with one point and one polygon, using invented names at arbitrary coordinates.

Loading editor…
Paste or type JSON on the left to explore it as a tree.
Empty🔒 Processed locally in your browser

The example

The JSON above is the example. Explore it in the Tree tab, press Download to save it as a .json file, or Share to send someone a link to it. All names, ids, emails and values are invented.

Fields explained

PathTypeNotes
typestringFeatureCollection holds a list of Feature objects.
features[].propertiesobjectFree-form attributes such as a name.
features[].geometry.typestringPoint, LineString, Polygon and others.
geometry.coordinatesarrayOrder is [longitude, latitude], the opposite of how most people say it.
Polygon ringarray of positionsThe first and last position of a ring must be the same, so the shape is closed.

Read it in code

JavaScript:

const [lng, lat] = data.features[0].geometry.coordinates;

Python:

lng, lat = data["features"][0]["geometry"]["coordinates"]

What this example is good for

Tips

Convert this example

Open it in a converter, then switch the output in the Code tab:

More examples

All JSON examples · Cheat sheets