- Point
- LineString
- Polygon
- MultiPoint
- MultiLineString
- MultiPolygon
- GeometryCollection
- A “Feature” object that can contain a geometric shape and some additional properties that describe that shape. This is useful, for example, when drawing maps on the internet in color, such as on geojson.io. For an example showing how to add color to a GeoJSON feature, see below.
- Features can additionally be grouped together into a “FeatureCollection”.
GeoJSON should only be used for spatial data that uses the geographic spatial reference system. For more information, see .
Example
In the example below, we will convert a shape represented in to GeoJSON using theST_AsGeoJSON .
Here is the WKT:
ST_AsGeoJSON function:
FeatureCollection in which each Feature has additional styling information (in the properties field) that can be used in visualization tools such as geojson.io:


