Announcement: All noncommercial projects registered to use Earth Engine before April 15, 2025 must verify noncommercial eligibility to maintain Earth Engine access.
Stay organized with collections
Save and categorize content based on your preferences.
You can export a FeatureCollection as CSV, SHP (shapefile), GeoJSON, KML, KMZ
or TFRecord using Export.table. The FeatureCollection may represent vectors
or simply a table of data. In the latter case, the features in the collection
will have null geometry.
Note some additional constraints when working with some file formats, including:
KML: A FeatureCollection exported to a KML file will have all the
geometries transformed to unprojected (WGS84) coordinates.
SHP: A FeatureCollection exported to a Shapefile must contain features
with the same geometry type and projection and must fit within the
Shapefile size
limits. Column
names are truncated to 10 characters or fewer, and this must not create
duplicate column names.
There are several limitations on the size and shape of Earth Engine table
assets:
Maximum of 100 million features
Maximum of 1,000 properties (columns)
Maximum of 100,000 vertices for each row's geometry
Maximum of 100,000 characters per string value
to BigQuery
You can export a FeatureCollection to a BigQuery table using
Export.table.toBigQuery().
This lets you integrate your Earth Engine data with other data and tools
available in BigQuery. For more information, see the
Exporting to BigQuery guide.
Note that the output format is specified as KML to handle geographic data (SHP
would also be appropriate for exporting a table with geometry). To export just a
table of data, without any geographic information, export features with null
geometry in CSV format. The following demonstrates using
Export.table.toDrive() to get the results of a potentially long running
reduction:
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-05-22 UTC."],[[["\u003cp\u003e\u003ccode\u003eExport.table\u003c/code\u003e allows you to export \u003ccode\u003eFeatureCollection\u003c/code\u003e data from Earth Engine in various formats like CSV, SHP, GeoJSON, KML, KMZ, and TFRecord, which can represent vector data or simply a table.\u003c/p\u003e\n"],["\u003cp\u003eWhen exporting, be aware of format-specific constraints such as coordinate systems for KML and geometry type/size limits for SHP.\u003c/p\u003e\n"],["\u003cp\u003eYou can export \u003ccode\u003eFeatureCollection\u003c/code\u003e data to your Google Drive, Cloud Storage, or as an Earth Engine asset using designated functions like \u003ccode\u003etoDrive()\u003c/code\u003e, \u003ccode\u003etoCloudStorage()\u003c/code\u003e, and \u003ccode\u003etoAsset()\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eFor exporting data without geographic information, use features with null geometry and export in CSV format, but be mindful of potential data type conversions in Google Drive.\u003c/p\u003e\n"],["\u003cp\u003eEarth Engine table assets have limitations on the number of features, properties, geometry vertices, and string value lengths.\u003c/p\u003e\n"]]],[],null,["# Exporting Table and Vector Data\n\nYou can export a `FeatureCollection` as CSV, SHP (shapefile), GeoJSON, KML, KMZ\nor TFRecord using `Export.table`. The `FeatureCollection` may represent vectors\nor simply a table of data. In the latter case, the features in the collection\nwill have null geometry.\n\nNote some additional constraints when working with some file formats, including:\n\n- **KML** : A `FeatureCollection` exported to a KML file will have all the geometries transformed to unprojected (WGS84) coordinates.\n- **SHP** : A `FeatureCollection` exported to a Shapefile must contain features with the same geometry type and projection and must fit within the [Shapefile size\n limits](https://support.esri.com/en/technical-article/000010813). Column names are truncated to 10 characters or fewer, and this must not create duplicate column names.\n- **TFRecord** : See [this page](/earth-engine/guides/tfrecord#exporting-tables).\n\n| **Note:** If you need control over the precision of geometries in your export, `map()` a function over the collection to be exported: `map(function(f) { return f.transform(targetProj, maxErr); })`\n\nto Cloud Storage\n----------------\n\nTo export a `FeatureCollection` to Cloud Storage, use\n`Export.table.toCloudStorage()`. For example, using the `features` defined\npreviously:\n\n### Code Editor (JavaScript)\n\n```javascript\n// Make a collection of points.\nvar features = ee.FeatureCollection([\n ee.Feature(ee.Geometry.Point(30.41, 59.933), {name: 'Voronoi'}),\n ee.Feature(ee.Geometry.Point(-73.96, 40.781), {name: 'Thiessen'}),\n ee.Feature(ee.Geometry.Point(6.4806, 50.8012), {name: 'Dirichlet'})\n]);\n\n// Export a KML file to Cloud Storage.\nExport.table.toCloudStorage({\n collection: features,\n description:'vectorsToCloudStorageExample',\n bucket: 'your-bucket-name',\n fileNamePrefix: 'exampleTableExport',\n fileFormat: 'KML'\n});\n```\nPython setup\n\nSee the [Python Environment](/earth-engine/guides/python_install) page for information on the Python API and using\n`geemap` for interactive development. \n\n```python\nimport ee\nimport geemap.core as geemap\n```\n\n### Colab (Python)\n\n```python\n# Make a collection of points.\nfeatures = ee.FeatureCollection([\n ee.Feature(ee.Geometry.Point(30.41, 59.933), {'name': 'Voronoi'}),\n ee.Feature(ee.Geometry.Point(-73.96, 40.781), {'name': 'Thiessen'}),\n ee.Feature(ee.Geometry.Point(6.4806, 50.8012), {'name': 'Dirichlet'}),\n])\n\n# Export a KML file to Cloud Storage.\ntask = ee.batch.Export.table.toCloudStorage(\n collection=features,\n description='vectorsToCloudStorageExample',\n bucket='your-bucket-name',\n fileNamePrefix='exampleTableExport',\n fileFormat='KML',\n)\ntask.start()\n```\n\nto Asset\n--------\n\nTo export a `FeatureCollection` as an Earth Engine asset, use\n`Export.table.toAsset()`. For example, using the `features` defined previously:\n\n### Code Editor (JavaScript)\n\n```javascript\n// Export an ee.FeatureCollection as an Earth Engine asset.\nExport.table.toAsset({\n collection: features,\n description:'exportToTableAssetExample',\n assetId: 'exampleAssetId',\n});\n```\nPython setup\n\nSee the [Python Environment](/earth-engine/guides/python_install) page for information on the Python API and using\n`geemap` for interactive development. \n\n```python\nimport ee\nimport geemap.core as geemap\n```\n\n### Colab (Python)\n\n```python\n# Export an ee.FeatureCollection as an Earth Engine asset.\ntask = ee.batch.Export.table.toAsset(\n collection=features,\n description='exportToTableAssetExample',\n assetId='projects/your-project/assets/exampleAssetId',\n)\ntask.start()\n```\n\nThere are several limitations on the size and shape of Earth Engine table\nassets:\n\n- Maximum of 100 million features\n- Maximum of 1,000 properties (columns)\n- Maximum of 100,000 vertices for each row's geometry\n- Maximum of 100,000 characters per string value\n\nto BigQuery\n-----------\n\nYou can export a `FeatureCollection` to a BigQuery table using\n[`Export.table.toBigQuery()`](/earth-engine/apidocs/export-table-tobigquery).\nThis lets you integrate your Earth Engine data with other data and tools\navailable in BigQuery. For more information, see the\n[Exporting to BigQuery guide](/earth-engine/guides/exporting_to_bigquery).\n\n### Code Editor (JavaScript)\n\n```javascript\nExport.table.toBigQuery({\n collection: features,\n table: 'myproject.mydataset.mytable',\n description: 'put_my_data_in_bigquery',\n append: true,\n overwrite: false\n});\n```\nPython setup\n\nSee the [Python Environment](/earth-engine/guides/python_install) page for information on the Python API and using\n`geemap` for interactive development. \n\n```python\nimport ee\nimport geemap.core as geemap\n```\n\n### Colab (Python)\n\n```python\ntask = ee.batch.Export.table.toBigQuery(\n collection=features,\n table='myproject.mydataset.mytable',\n description='put_my_data_in_bigquery',\n append=True,\n overwrite=False,\n)\ntask.start()\n```\n\nto Drive\n--------\n\nTo export a `FeatureCollection` to your Drive account, use\n`Export.table.toDrive()`. For example:\n\n### Code Editor (JavaScript)\n\n```javascript\n// Export the FeatureCollection to a KML file.\nExport.table.toDrive({\n collection: features,\n description:'vectorsToDriveExample',\n fileFormat: 'KML'\n});\n```\nPython setup\n\nSee the [Python Environment](/earth-engine/guides/python_install) page for information on the Python API and using\n`geemap` for interactive development. \n\n```python\nimport ee\nimport geemap.core as geemap\n```\n\n### Colab (Python)\n\n```python\n# Export the FeatureCollection to a KML file.\ntask = ee.batch.Export.table.toDrive(\n collection=features, description='vectorsToDriveExample', fileFormat='KML'\n)\ntask.start()\n```\n\nNote that the output format is specified as KML to handle geographic data (SHP\nwould also be appropriate for exporting a table with geometry). To export just a\ntable of data, without any geographic information, export features with null\ngeometry in CSV format. The following demonstrates using\n`Export.table.toDrive()` to get the results of a potentially long running\nreduction:\n\n### Code Editor (JavaScript)\n\n```javascript\n// Load a Landsat image.\nvar image = ee.Image('LANDSAT/LC08/C02/T1_TOA/LC08_044034_20140318');\nvar projection = image.select('B2').projection().getInfo();\n\n// Create an arbitrary rectangle.\nvar region = ee.Geometry.Rectangle(-122.2806, 37.1209, -122.0554, 37.2413);\n\n// Get a dictionary of means in the region.\nvar means = image.reduceRegion({\n reducer: ee.Reducer.mean(),\n geometry: region,\n crs: projection.crs,\n crsTransform: projection.transform,\n});\n\n// Make a feature without geometry and set the properties to the dictionary of means.\nvar feature = ee.Feature(null, means);\n\n// Wrap the Feature in a FeatureCollection for export.\nvar featureCollection = ee.FeatureCollection([feature]);\n\n// Export the FeatureCollection.\nExport.table.toDrive({\n collection: featureCollection,\n description: 'exportTableExample',\n fileFormat: 'CSV'\n});\n```\nPython setup\n\nSee the [Python Environment](/earth-engine/guides/python_install) page for information on the Python API and using\n`geemap` for interactive development. \n\n```python\nimport ee\nimport geemap.core as geemap\n```\n\n### Colab (Python)\n\n```python\n# Load a Landsat image.\nimage = ee.Image('LANDSAT/LC08/C02/T1_TOA/LC08_044034_20140318')\nprojection = image.select('B2').projection().getInfo()\n\n# Create an arbitrary rectangle.\nregion = ee.Geometry.Rectangle(-122.2806, 37.1209, -122.0554, 37.2413)\n\n# Get a dictionary of means in the region.\nmeans = image.reduceRegion(\n reducer=ee.Reducer.mean(),\n geometry=region,\n crs=projection['crs'],\n crsTransform=projection['transform'],\n)\n\n# Make a feature without geometry and set the properties to the dictionary of means.\nfeature = ee.Feature(None, means)\n\n# Wrap the Feature in a FeatureCollection for export.\nfeature_collection = ee.FeatureCollection([feature])\n\n# Export the FeatureCollection.\ntask = ee.batch.Export.table.toDrive(\n collection=feature_collection,\n description='exportTableExample',\n fileFormat='CSV',\n)\ntask.start()\n```\n\nNote that the format is set to 'CSV' in this example since there is no geometry\nin the output.\n| **Caution:** Depending on your Google Drive settings, CSV tables that you export from Earth Engine can be converted to XSLX files with unintended effects, such as data type conversions. The behavior can be modified with [Google Drive\n| settings](/earth-engine/faq#tables_exported_to_drive_as_csv_format_are_converted_to_xslx_format)."]]