Back to Marketstack in Google Sheets
SheetXAI logo
Marketstack logo
Marketstack · Google Sheets Guide

Export the Full Marketstack Exchange Catalog Into a Google Sheet

2026-05-14
5 min read

The Scenario

You are building a stock-lookup tool for the research team. The core of it is a reference table: every exchange that Marketstack supports, with the MIC code, exchange name, country, and city, so users can look up the right exchange for a given ticker before pulling data.

You could go to Marketstack's documentation and start copying exchange records by hand. The Marketstack site lists exchanges, but not in a format that lands cleanly in a spreadsheet. And you need all of them — not a curated selection, not the major ones, all 72+ exchanges — so the tool is complete when it ships.

The tool is supposed to go live by end of week.

The bad version:

  • Call Marketstack's exchanges endpoint, get the first page of results, count how many records came back, and realize pagination is required to get the full list
  • Copy the first page of records into the sheet, then manually call the next page, copy those, repeat until you have hit every page and assembled the full table
  • Discover that the city field is missing for a handful of exchanges and decide whether to leave those cells blank or fill them manually from the exchange's website

The reference table is infrastructure for the actual tool. It should not take most of a workday to build.

The Easy Way: One Prompt in SheetXAI

SheetXAI is an AI agent that lives inside your Google Sheet. It reads the sheet context and through its Marketstack integration it can fetch the complete exchange catalog — all pages — and write it into the sheet in one operation.

Fetch all supported stock exchanges from Marketstack and write the MIC code, exchange name, country, and city into this sheet — one exchange per row, sorted alphabetically by country

What You Get

  • One row per exchange across the full Marketstack catalog
  • Four columns: MIC Code, Exchange Name, Country, City
  • Sorted alphabetically by country so the table is easy to scan and filter
  • Exchanges with missing city data get a blank cell rather than an error, keeping the table clean

What If the Data Is Not Quite Ready

You want a fifth column for the exchange website URL

Fetch all supported exchanges from Marketstack and write MIC code, exchange name, country, city, and website URL into this sheet — one exchange per row, sorted by country

You only want exchanges that are currently active

Fetch all Marketstack exchanges and write MIC, name, country, and city into this sheet — include only exchanges where the status is active, and add a note in a separate row counting how many active exchanges are in the list

You want exchanges grouped by continent rather than sorted by country name

Fetch all Marketstack exchanges and write MIC code, name, country, continent, and city into this sheet — group the rows by continent and sort alphabetically within each continent group

Full reference build: fetch all exchanges, add a country summary count, and add a lookup formula column

Fetch all Marketstack exchanges and write MIC, name, country, and city into a sheet called Exchange Reference; add a Country Summary tab counting exchanges per country sorted by count descending; and add a formula in column E of the main sheet that shows the total number of other exchanges in the same country as each row

Combining the catalog pull, the summary, and the formula in one prompt means the reference table is complete and navigable rather than just a raw data dump.

Try It

Get the 7-day free trial of SheetXAI and open a blank Google Sheet, then ask it to write the full Marketstack exchange catalog into the sheet. The Marketstack integration is included in every SheetXAI plan.

See also: looking up exchange details by MIC code and enriching tickers with metadata.

Stop memorizing formulas.
Tell your spreadsheet what to do.

Join 4,000+ professionals saving hours every week with SheetXAI.

Learn more