arcuser

Migrating Your Data from ArcGIS Online to an Enterprise Geodatabase

In today’s data-driven world, organizations are looking to optimize their geospatial data management workflows. Migrating data from ArcGIS Online to an enterprise geodatabase can be a transformative step that provides numerous benefits. For example, with enterprise geodatabases, you can take advantage of functionality that is unique to an enterprise geodatabase, such as versioning. Versioning allows multiple users to edit data simultaneously, in isolation from one another, with the option to review any conflicts. This helps organizations with many editors more effectively manage updates to their most critical GIS datasets.

Regardless of the motivations for migrating your data, having a good understanding of the available options is crucial to avoiding potential complications.

However, there are a few prerequisites to begin the migration process. First, you must own the features associated with your ArcGIS Online login or be an administrator, or the owner or administrator must configure the layer to allow others to export data. Second, you must determine what format to use when exporting data. There are multiple options with different benefits and drawbacks. You will also need an enterprise geodatabase connection with a database user who has permissions to add data.

Screenshot of the Export Data drop-down menu in ArcGIS Online.
Access the Export Data option from ArcGIS Online from the item page.

Export Data from ArcGIS Online

The Export Data menu is the primary option to download data from ArcGIS Online. This tool generates an item within your content in ArcGIS Online that encompasses the data from the selected layers in different formats. You can then download the data from that item to be used in ArcGIS Pro, Microsoft Excel, and elsewhere. The tool can be accessed from the item page when you want to download the full dataset.

There are multiple output formats to choose from. Depending on your workflow, you might choose one output format over the other.

Screenshot of the Extract data menu, indicating each source that can be selected.
The Extract Data tool can pull from multiple layers with different sources.

Alternately, you can access your data in Map Viewer using the Extract Data tool. This tool is located on the Analysis tab, and allows for more customization than the Export Data option on the item page.

Using the Extract Data tool, you can extract data from multiple web layers from different sources as input. You can also specify an extent to extract data, with the option to clip features based on that extent.

Screenshot of the Extent settings menu, including the Extent layer and a clip features checkbox.
You can specify an extent to extract data with the Extract Data tool.

The Extract Data tool also comes with the ability to name the output file—which can only be a file geodatabase, .csv file, shapefile, or .kml file—and select the output folder. The Environment settings pane allows you to define the output coordinate system and the processing extent.

Screenshot of the Environment settings pane with the “same as layer” option highlighted in blue.
The Environment settings pane allows you to define the output coordinate system and the processing extent.

If the web layer you want to export doesn’t have the export option, ensure the Allow others to export to different formats option is checked.

Your output will be a hosted item containing a downloadable .csv file, file geodatabase, .kml file, or shapefile. You will then need to use the layer options to download the file locally before the data can be migrated to an enterprise geodatabase.

Screenshot of the Result layer pane for the Extract Data tool, including the options Output data format, Output name, and Save in folder.
With the Extract Data tool, you can name the output file and select the output folder.

Import or Export Data from ArcGIS Online Using ArcGIS Pro

When accessing hosted feature camlayers in ArcGIS Pro, there are options available to import or export the data directly into an enterprise geodatabase.

First, it is necessary to connect to your ArcGIS Online account. You must be the owner of the data, or an administrator. If you are not the data owner or administrator, those users will need to share the dataset with you and configure the dataset to allow others to export the data. Sign in on the upper right corner of the ArcGIS Pro project.

To migrate the feature layer to an enterprise geodatabase, select your enterprise connection in the Catalog pane.

Click Import, then select Feature Class(es). The Feature Class To Geodatabase geoprocessing tool will open.

Screenshot of three separate panes in ArcGIS Pro outline the path to importing a feature class. The first pane is labeled Catalog. On the second pane, Import is highlighted. On the third pane, Feature Class(es) is highlighted.
The path to import a feature class to an enterprise geodatabase.

Note that choosing the Export option would also use the Feature Class To Geodatabase geoprocessing tool. A benefit of using Import is that it automatically populates the output enterprise geodatabase. Verify that the enterprise geodatabase connection is set for the data owner.

On the Feature Class To Geodatabase geoprocessing tool, select the browse button on the Input Features parameter. Select feature layers from ArcGIS Online or from a location downloaded from ArcGIS Online. You may need to extract the data first if the download is a .zip file.

Screenshot of the Geoprocessing pane, with POI listed under Input features.
Use the Feature Class to Geodatabase geoprocessing tool to import a feature class.

Verify the output geodatabase connection and environment settings before running the geoprocessing tool. For example, double-check the following options on the Environments tab:

Screenshot of an option to download AnalysisInputData from ArcGIS Online, with other options blurred out.
The download option for the resultant file geodatabase.

Export Features Option

Another way to migrate your data from ArcGIS Online to an enterprise geodatabase is within an active map in ArcGIS Pro. After adding the desired hosted web feature layer to the map, access the Export Features tool from the layer’s right-click context menu or from the Data tab on the ribbon. The output parameter can be set to convert the layer to a feature class directly in your enterprise geodatabase.

Screenshot of three separate panes in ArcGIS Pro outline the path Export Featuress. The first pane is labeled Contents. On the second pane, Data is highlighted. On the third pane, Export Features is highlighted.
The path to the Export Features option in ArcGIS Pro.

The tool allows for a single layer input, but you can customize it in several ways. Use it to define a SQL expression to select a subset of features; add, remove, reorder, and rename fields in the output feature class; or change field data type and merge field values into a single field.

Screenshot of the Export Features Parameters pane, with options such as Input Features and Output Feature Class.
The Export Features geoprocessing tool allows for a single layer input with a variety of customization.

Finally, using the Environments tab, you can define a new coordinate system and preserve certain geodatabase functionalities such as the following:

Note that you can also choose Export Table to export to a stand-alone table.

Sometimes the Export Features option will be grayed out on the web feature layer. Selecting Export Data avoids this situation. If you are a publisher in your organization and use ArcGIS Pro to share data with ArcGIS Online, enable the Export Data option during the publishing process. This controls whether a user other than the portal administrator or data owner can export the features from a web feature layer.

If you are not a publisher of the hosted layer or an administrator making changes to the existing web layer, try importing or exporting the data.

Screenshot of Share As Web Layer Configuration pane, with the Export Data checkbox highlighted in a green box.
The Environment settings pane allows you to define the output coordinate system and the processing extent.

Download Data from ArcGIS Online Using ArcGIS API for Python

If you are a developer looking to eliminate manual steps or work with large volumes of data, you can download a copy of all your hosted web layers using ArcGIS API for Python. To extract data from one or more layers within a given extent, use the extract_data method. The extracted data format can be a file geodatabase, shapefiles, .csv, or .kml. Download and extract data with .zip files (such as File geodatabases and shapefiles) prior to using this method.

Downloading Services with Attachments

Downloading large feature services with attachments using the REST API can be challenging due to file size limitations. However, you can manage this by splitting the data into smaller batches. You can export subsets of the feature service data with attachments to a replica from a REST endpoint. Access this method from the View Details page. The Feature Service link opens the ArcGIS REST Services Directory page. A WHERE clause can be set to create a subset replica to an output URL. Once the replica creation is complete, download the .zip file and reference the data to migrate to your enterprise geodatabase.

When migrating data from ArcGIS Online to an enterprise geodatabase, there are multiple options to suit various workflow needs. Whether you are using the Export Data menu in ArcGIS Online, tools such as Feature Class To Geodatabase within ArcGIS Pro, or ArcGIS API for Python for large volumes of data, understanding and using these diverse options ensures that your organization can benefit from a seamless migration process and enhances your geospatial data management capabilities.

About the authors

Mike Jensen

Mike Jensen loves to enhance the customer experience of Esri software and has many opportunities to do so as a product engineer on the geodatabase team at Esri. In addition to his GIS career, he loves to tinker with tech gadgets, beat on the drums, bake pies and brownies, tell and snicker at dad jokes, and enjoy quiet time in the country with family and friends.

Diana Muresan

Diana Muresan is a product engineer on the geodatabase team at Esri. Muresan is passionate about making a difference in people’s lives using GIS. She is also a hiker and a true éclair and crepe lover in her free time.