HOW TO

Convert a JSON query result of a feature service from an ArcGIS REST endpoint to an Excel file

Last Published: November 13, 2020

Summary

When querying a feature service in ArcGIS REST API, a response is returned based on the request parameters. It is possible to extract the response using a third-party application, such as Microsoft Excel or Google Drive. Converting JSON query results to an Excel file or a CSV format allows users to save, view, and share data conveniently.

Procedure

Follow the steps below to convert a JSON query result of a feature service from an ArcGIS REST endpoint to an Excel file or a CSV format.

  1. Log in to www.arcgis.com.
  2. Click My Content, and navigate to the feature service to open its item details page.
  3. On the item details page, scroll to the URL section, and click View to access the ArcGIS REST Services Directory page.
  4. Select a layer to query under the Layers list.
Image showing the Layers list
  1. Scroll to the bottom of the page, and click Query in the Supported Operations section.
Image of Supported Operations option in ArcGIS REST Directory
  1. On the Query page, fill in the request parameters. Execute the query, and copy the URL of the JSON resulting web page. In this example, the parameters are set as follows:
    1. For the Where clause, 1=1 is used to display all the data within the feature service.
    2. For Format, select JSON from the drop-down list.
    3. Click Query (GET) or Query (POST) to render a result.
    4. Copy the URL of the JSON resulting web page.
  2. In Microsoft Excel, click the Data tab, and click Get Data > From Other Sources > From Web. Paste the URL copied in Step 5d in the URL text box. Click OK.
  3. A window with the JSON results displays. Click Load.
  4. The JSON results are loaded in the Excel file. Save the file in the desired format.
Image showing the JSON results loaded in the Excel file

Article ID: 000024412

Software:
  • ArcGIS REST API
  • ArcGIS Online

Receive notifications and find solutions for new or common issues

Get summarized answers and video solutions from our new AI chatbot.

Download the Esri Support App

Related Information

Discover more on this topic

Get help from ArcGIS experts

Contact technical support

Download the Esri Support App

Go to download options