Skip to content
GaleriGIS

SHP to GeoJSON converter

Turn a Shapefile into one .geojson file for web maps and code. Zip the Shapefile parts and drop the ZIP here. The file is read in your browser and is not uploaded to our server.

  • Reads the .prj and reprojects to WGS 84
  • Attributes become GeoJSON properties
  • One readable FeatureCollection file
  • 3 free files, then unlimited with GaleriGIS Toolbox
Input: Shapefile in a ZIP

Drop a Shapefile .zip

or click to choose a file, up to 3 MB

How to convert a Shapefile to GeoJSON

  1. Put the Shapefile parts in one ZIP: .shp, .shx and .dbf are needed, and .prj should be included.
  2. Drop the ZIP into the box above. The .geojson downloads when the conversion is done.
  3. Load the file in Leaflet, MapLibre, OpenLayers, geojson.io, or read it in your own code.

Shapefile and GeoJSON compared

ShapefileGeoJSON
FilesSeveral: .shp, .shx, .dbf, .prjOne
ContentBinaryJSON text you can read and edit
Coordinate systemAny, described in the .prjWGS 84 longitude and latitude
Field namesUp to 10 charactersAny length
Where it is at homeDesktop GISWeb maps, APIs, scripts

What the GeoJSON looks like

The output is a single FeatureCollection, indented so it can be read and compared in a text editor or a version control system. Each record of the Shapefile becomes one Feature:

  • Geometry: Point, LineString or Polygon, or the Multi version when a record has several parts.
  • Properties: one entry for each field of the .dbf, under the field name used in the Shapefile. Numeric fields stay numbers and text fields stay text.
  • Coordinates: longitude first, then latitude, as the GeoJSON standard (RFC 7946) expects.

If the ZIP holds several shapefiles, their features are put together in the same FeatureCollection.

Why the .prj file matters

GeoJSON uses WGS 84 longitude and latitude. Many Shapefiles are stored in a projected system such as UTM or US State Plane, with coordinates in meters or feet. The .prj file says which system the data uses. When it is in the ZIP, the converter reads it and transforms the coordinates to WGS 84.

Without a .prj, the coordinates are copied as they are. If they are not longitude and latitude, a web map will show the data in the wrong place or not at all. Open the Shapefile in QGIS or ArcGIS, set the correct coordinate system and export it again.

Common problems

The ZIP cannot be read

  • The ZIP needs at least .shp, .shx and .dbf.
  • All parts of one Shapefile must share the same name, for example parcels.shp, parcels.shx, parcels.dbf.
  • If it still fails, export the layer again from your GIS software. Very complex geometry can also be simplified first.

Nothing shows on my web map

Open the .geojson and look at the first coordinates. Longitude must be between -180 and 180 and latitude between -90 and 90. Values in the hundreds of thousands mean the data is still in a projected system: the .prj was missing from the ZIP. See the section above.

Accented characters come out wrong

The attribute table is stored in an older text encoding and the Shapefile does not say which. Export the layer again from your GIS software with UTF-8 encoding, and keep the .cpg file it writes in the ZIP.

The file is too large

The free tool handles ZIP files up to 3 MB. Keep in mind that GeoJSON is text and the result is larger than the Shapefile it came from. For larger files or many files at once, use GaleriGIS Toolbox.

GaleriGIS Toolbox

$15 per month

  • No conversion limit on every GaleriGIS online converter
  • Several files at once, and larger files
  • DWG and DXF in any UTM zone or EPSG code, KML/KMZ, Shapefile, GeoJSON, Excel and coordinates
  • Files stay in your browser. Billed monthly, cancel any time

Payments are processed by Creem, our merchant of record. See our refund policy and terms.

Frequently asked questions

Is my file uploaded?

No. The Shapefile is read and converted inside your browser. Only the converter code is downloaded from our server.

Can I convert a single .shp file without the other parts?

No. The geometry is in the .shp, but the index (.shx) and the attributes (.dbf) are separate files, so the tool asks for them together in a ZIP.

Are the field names changed?

No. Properties keep the names of the Shapefile fields, including the 10 character limit they were saved with.

How many files are free?

Three. After the third file the free quota fills up again over the next one to three days. GaleriGIS Toolbox has no limit.

I need the opposite direction

Use the GeoJSON to SHP converter. To open a Shapefile in Google Earth, use SHP to KML.

More GaleriGIS tools