Convert TOPOJSON to CSV

Turn TOPOJSON files into CSV. A CSV with one row for each feature: its shape as WKT in a first column named WKT, then every attribute as a column.

Converted in an isolated sandbox on our serversDeleted after 24 hours

Drop TOPOJSON files on the dialor turn it to pick what to do

A table of your map's shapes and attributes.One row per feature, with its shape as WKT and every attribute as a column.

  1. What you get

    A CSV with one row for each feature. The first column is named WKT and holds the feature's shape as WKT. Every attribute follows as its own column.

    Coordinates are written in WGS 84 longitude and latitude. The result is one file.

  2. What changes

    Features without a geometry keep their row, with an empty WKT. If a column is already named WKT, it is renamed WKT_1 so the shape column keeps its name.

    Lists and nested values become JSON text in their cell, because a CSV cell holds only plain text.

  3. Several layers

    When the TopoJSON has several layers, they are joined into one CSV. A layer column names the layer each feature came from.

    To work with the table afterward, see merge CSV. For other conversions to this format, see every CSV conversion.

TOPOJSON and CSV.What each format is.

The formats

From · TOPOJSON

TopoJSON

TopoJSON, GeoJSON's compact cousin that shares borders between shapes, as D3 maps use it.

Extensions
.topojson
MIME type
application/topo+json
Kind
Text and data
To · CSV

CSV

Rows of comma-separated values. The plainest way to move a table between programs.

Extensions
.csv
MIME type
text/csv
Kind
Text and data

In your code.The same TOPOJSON to CSV conversion through the API, for your app or your agent.

terminal
$ cv convert report.topojson report.csv
$ cv convert report.topojson report.csv

Questions.What people ask about TOPOJSON to CSV.

01OF 04

It is in the first column, named WKT, written as WKT text. Each feature's attributes follow in the columns after it.

They keep their row. The WKT cell is empty and the attributes are still there.

That attribute is renamed WKT_1. The first column named WKT holds the shape.

Yes, as JSON text. Lists and nested values are written into their cell in that form.

More conversions.Other ways in and out of TOPOJSON and CSV.