A dataset is an editable collection of GeoJSON features. Datasets can be uploaded to Mapbox via Mapbox Studio or the Datasets API, and can be edited in the Mapbox Studio dataset editor.
Datasets and tilesets
Datasets and tilesets are two different types of data. Datasets provide access to feature geometries and properties (attributes), both of which can be edited in the Mapbox Studio dataset editor or through the Datasets API. Datasets also keep full data fidelity. Tilesets are lightweight collections of vector data that are optimized for rendering and are not editable. When datasets are exported to tilesets for display, the resulting tileset often has simplified geometry optimized for viewing at specific zoom levels.
A typical workflow for using datasets in Mapbox Studio is:
- Upload your data file to Mapbox Studio as a dataset
- Edit your dataset in the Mapbox Studio dataset editor
- Export your dataset to a tileset
- Add the tileset to a style in the Mapbox Studio style editor
Creating a dataset
You can create a dataset from scratch in the Mapbox Studio dataset editor or through the Mapbox Datasets API. Note that the process involves two steps in each case: creating an empty dataset, and adding features to that dataset.
In Mapbox Studio, you can add features to a dataset by drawing them in the dataset editor or uploading a GeoJSON or CSV file. Using the Datasets API, you can add features by making requests to either insert a feature or to batch add features. You cannot upload a file directly through the Datasets API.
Downloading a dataset
To download a created dataset, click Download as GeoJSON on the dataset info page or download through the Datasets API.