Connect to a JSON file

You can create a dynamic connection between an Excel workbook and a JSON file, then refresh the connection whenever the JSON data changes.

Use Excel's Get & Transform (Power Query) experience to connect to a JSON file.

  1. Click the Data tab, then Get Data > From File > From JSON.

  2. Browse to your JSON file location, select it, and click Open.

  3. Once the Query Editor has loaded your data, click Convert > Into Table, then Close & Load.

You can also use the Query Editor to create formulas to connect to JSON files. If you don't see the Get Data button, you can go to New Query > From Other Sources > Blank Query, then go to Advanced Editor and input your custom query string.

let

Source = Json.Document(File.Contents("C:\Users\Name\Desktop\JSONTest.json")), #"Converted to Table" = Record.ToTable(Source)

in

#"Converted to Table"

You can also use the Query Editor to create formulas to connect to JSON files. In the Power Query ribbon tab, click From Other Sources > Blank Query, then go to Advanced Editor and input your custom query string.

let

Source = Json.Document(File.Contents("C:\Users\Name\Desktop\JSONTest.json")), #"Converted to Table" = Record.ToTable(Source)

in

#"Converted to Table"

Need more help?

You can always ask an expert in the Excel Tech Community, get support in the Answers community, or suggest a new feature or improvement on Excel User Voice.

See Also

Power Query is known as Get & Transform in Excel 2016

Import data from external data sources

Get support
Contact us
Expand your Office skills
Explore training

Was this information helpful?

Thank you for your feedback!

Thank you for your feedback! It sounds like it might be helpful to connect you to one of our Office support agents.

×