U.S. flag

An official website of the United States government

Access the API: Converting JSON Data

Open an Excel file. It does not need to be blank since this process will create a new sheet.

Go to the Data tab → Get Data → From File → From JSON

Open an excel file

Browse and select the JSON file you want to convert. This will open the Excel Power Query Editor.

In the Power query editor, click the “To Table” button in the top left.

To table

Then in the “To table” popup, leave the options as-is and click OK.

To table popup

Click the Left right arrow symbol to expand the table columns.

Expand table options

Uncheck the bottom checkbox “Use original column name as prefix” and click OK.

Search columns to expand

You should now see the expanded columns of the API results, with one row per query in your request.

Expanded columns

Click “Close and Load” in the top-left to move this data into your Excel spreadsheet and exit the Power Query Editor.

Close and load

Your results should appear in their own Excel sheet, which is named based on the filename of the JSON file you selected (i.e. output_file.json creates a sheet called “output_file”).