CDXGeoStream

Help & support

Everything you need to use CDXGeoStream in Excel, Google Sheets, and LibreOffice Calc.

Getting started

CDXGeoStream adds ZIP-code distance, lookup, radius, demographics, and geocoding functions to your spreadsheet. Three steps to get going:

  1. Set your API key. Open the CDXGeoStream pane in your spreadsheet and paste your key. No key yet? See plans & buy ↗
  2. Type a function in any cell, e.g. =CDX.DISTANCE("10001","94105").
  3. Need a hand? Contact support ↗

Which tab do I click? Use Cell formulas to put a =CDX.* formula in one cell, and Bulk tools to run a job over a whole column and write the results to a new sheet.

Tip — point at cells & fill down. Reference cells instead of typing values, e.g. =CDX.DISTANCE(A2, B2), then copy the formula down the column to compute every row (the add-in batches the calls for you). In Google Sheets you can also pass a whole range at once: =CDXCITY(A2:A100). How cell references & filling down work ↗

Finding a function. The Insert panel has a search box — type what you want to do (address, distance, closest) rather than hunting through the categories. Once you pick one, only its required arguments are shown; anything else lives under Advanced options. Filling in just the visible boxes is the intended way to use it.

Install CDXGeoStream

Pick where you want to install CDXGeoStream. The steps genuinely differ per host.

Excel on the web

  1. 1Download the manifest (a small .xml file). Always use this copy — it points at the live CDXGeoStream servers.
  2. 2In Excel on the web, open a workbook and choose Home ▸ Add-ins.
  3. 3Click More Add-ins, then the My Add-ins tab, then Upload My Add-in (top right).
  4. 4Browse… to the manifest you downloaded and choose Upload. The CDXGeoStream button appears on the Home tab.
  5. 5Open the CDXGeoStream pane and paste your API key when prompted. The key is stored for this Excel install; the cell functions read the same key, so =CDX.CITY("90210") starts working immediately.

Uploading a manifest this way installs the add-in for this browser and this workbook. It stays until you clear the browser’s cached add-ins — reload the workbook and it comes back. Nothing is installed on your machine.

Excel for Windows (desktop)

  1. 1Download the manifest and save it into a folder you can share — e.g. C:\CDXGeoStream.
  2. 2Right-click that folder ▸ Properties ▸ Sharing ▸ Share… and share it with yourself. Copy the full network path it shows (it looks like \\YOURPC\CDXGeoStream).
  3. 3In Excel: File ▸ Options ▸ Trust Center ▸ Trust Center Settings… ▸ Trusted Add-in Catalogs.
  4. 4Paste the network path into Catalog Url, click Add catalog, tick Show in Menu, then OK. Close and reopen Excel.
  5. 5Insert ▸ My Add-ins ▸ Shared Folder → select CDXGeoStream → Add.
  6. 6Open the CDXGeoStream pane and paste your API key when prompted. The key is stored for this Excel install; the cell functions read the same key, so =CDX.CITY("90210") starts working immediately.

The shared-folder catalog is Microsoft’s supported way to install an add-in that isn’t from the store — the folder only needs to be shared, not on a server, and it can be your own PC. Requires Microsoft 365 or Office 2021 or newer: the add-in uses a shared runtime, which older Office builds do not support.

Excel for Mac (desktop)

  1. 1Download the manifest.
  2. 2In Finder press ⇧⌘G and go to: ~/Library/Containers/com.microsoft.Excel/Data/Documents/wef
  3. 3If the wef folder does not exist, create it. Copy the manifest into it.
  4. 4Restart Excel, then choose Insert ▸ My Add-ins and pick CDXGeoStream. (If it isn’t listed, quit Excel completely — ⌘Q — and reopen.)
  5. 5Open the CDXGeoStream pane and paste your API key when prompted. The key is stored for this Excel install; the cell functions read the same key, so =CDX.CITY("90210") starts working immediately.

Requires Microsoft 365 or Office 2021 or newer. The wef folder is Excel’s sideload location on macOS; files placed there are picked up at startup only, which is why the restart matters.

LibreOffice Calc

  1. 1Download the extension — CDXZip.oxt, version 0.12.1. One file works on Windows, macOS and Linux.
  2. 2Double-click the file. LibreOffice opens the Extension Manager and asks you to confirm. (Equivalent: Tools ▸ Extension Manager… ▸ Add.)
  3. 3Restart LibreOffice — close every window, including any hidden Start Center, then reopen Calc.
  4. 4In Calc, choose CDXGeoStream ▸ Set API key… from the menu bar and paste your key. Then CDXGeoStream ▸ Check key & credits to confirm it works — that check is free and doesn’t use any credits.
  5. 5Try it: right-click a cell ▸ CDXGeoStream ▸ Insert CDXGeoStream function…, or type =CDXCITY("90210") directly.

Already have an older version? Install this one over the top — the Extension Manager replaces it and your API key is kept. If you are on 0.1.x this is required: 0.2.0 changed the add-in’s internal interface, so an 0.1.x copy will not load at all.

Linux only: the add-in is written in Python, and some distributions ship LibreOffice without Python support. If the functions are missing after a restart, install python3-uno (Debian/Ubuntu: sudo apt install python3-uno) and restart again. Windows and macOS builds include Python already.

List functions need a range. Unlike Excel, Calc doesn’t spill automatically — a single cell shows only the first result. Either use Insert function… and tick Fill a range for me, or select the range first and press Ctrl+Shift+Enter instead of Enter.

Google Sheets

  1. 1Open your sheet and choose Extensions ▸ Apps Script.
  2. 2Download Code.gs and paste its contents over everything in the editor, replacing the default Code.gs. Click Untitled project at the top and rename it CDXGeoStream — the add-on's menu takes the project's name. Save.
  3. 3Reload the sheet, then run Extensions ▸ CDXGeoStream ▸ Authorize add-on once. Google asks for permission to make external requests — required before any cell function works.
  4. 4Extensions ▸ CDXGeoStream ▸ Settings and paste your API key. It is stored for your Google account only. Cell functions in a sheet use the sheet owner's key, so in a sheet someone shares with you, the owner's credits pay for them.
  5. 5Try it: =CDXCITY("90210"), or open the sidebar's Bulk tools tab for the report tools.

Updating? Repeat steps 1–2 — paste the new Code.gs over the old one. Sheets has no automatic update, so an existing sheet keeps running whatever version was pasted into it until you replace it. Your API key is stored separately and survives the paste — except once: the update that made keys private to each user needs it re-entered in Extensions ▸ CDXGeoStream ▸ Settings. The CDXGeoStream menu now sits under Extensions, named after the Apps Script project — rename the project CDXGeoStream (step 2) if it shows another name.

Cell references & filling down

Every CDX function can take its inputs from cells, not just typed-in values — so you can compute a whole sheet at once. A few details differ between Excel, Google Sheets, and LibreOffice Calc.

Reference a cell

Point an argument at a cell instead of typing a value: =CDX.DISTANCE(A2, B2) uses the ZIPs in A2 and B2. In the Insert wizard, just type a cell address (like A2) into a field. Works in all three apps.

Use a named range

Anywhere a function takes a range, you can give it a defined name or a table column instead of an address: =CDX.CLOSESTZIP(A2, StoreZips) or =CDX.CLOSESTZIP(A2, Table1[Zip]). Type the name into the Insert wizard's range field and it goes in unquoted.

  • A name must cover one continuous block of cells. A name built from several separate areas only uses the first.
  • A name scoped to one sheet can only be used on that sheet — Excel answers #NAME? elsewhere.
  • Point it at the cells you need, not a whole column: a range of more than 5,000 values is refused with #NUM!.

Apply it to many rows

  • Excel — put the formula in the first row (=CDX.DISTANCE(A2, B2)), then drag the fill handle (or copy/paste) down the column. References shift per row, and the add-in automatically batches the calls — thousands of rows resolve in just a few requests.
  • Google Sheets — fill down works the same, or hand a whole range to the first argument and get the column back in one formula: =CDXCITY(A2:A1000).
  • LibreOffice Calc — fill down just like Excel. Use your locale's argument separator (often ;): =CDXDISTANCE(A2;B2).

List functions (RADIUS, ZIPLIST)

These already return a whole list, so don't fill them down. Excel and Google Sheets spill the results automatically — use List output direction in Insert defaults to choose down-a-column or across-a-row. LibreOffice fills the cells below the formula.

Canadian postal codes 🍁

The location functions accept Canadian postal codes (e.g. M5H 2N2) anywhere they take a US ZIP, and a Canadian province anywhere they take a US state. Distances and routes work cross-border — e.g. =CDX.DISTANCE("M5H 2N2", "10001") (Toronto → New York).

  • Where it applies — CITY, STATE, COUNTY, ZIPLIST, DISTANCE, RADIUS, CLOSESTZIP, GEOCODE, REVGEOCODE, ROUTE, and the demographics functions (CENSUS, CITYDATA, COUNTYDATA, STATEDATA). (VERIFY is US-only — it is a USPS service.)
  • County & demographics — COUNTY returns the Census Division (Canada's county equivalent). Demographics come from Statistics Canada's census: CENSUS resolves a postal code to its Forward Sortation Area (the first 3 characters); CITYDATA, COUNTYDATA and STATEDATA use the census subdivision (municipality), census division, and province.
  • Included on every plan — Canadian data is available to all accounts, no add-on required.
  • Fields without a Canadian equivalent — a few demographic fields are US-only and return no value for Canada: per-capita income, the US race/ethnicity breakdowns, vacancy rate, and business counts. (Poverty maps to Canada's low-income measure.)

Distance matrix

The Distance matrix tool (Bulk tools → Distance & proximity) measures every location in List A against every location in List B and writes the result as a grid on a new sheet. Select a column and click Set List A from selection, do the same for List B, pick a method, and build.

  • Straight-line — distance as the crow flies, between ZIP codes. One grid, up to 500 × 500.
  • Driving — real road distance and drive time, for ZIP codes, postal codes, street addresses or "lat,lng". Two grids (distance and drive time), up to 500 × 500.
  • Bigger lists — the tool stops before anything is charged and tells you the limit. Shorten one list, or split it and build the grid in pieces; each piece is priced on its own.
  • Cost — the tool shows the rate before you build. A build over 5 credits shows its total and waits for a second click to confirm; a smaller one runs straight away. How it is worked out is under How credits work.

How credits work

Every operation costs credits, and there are only four ways one is priced — plus a single surcharge, when you hand a route or a map a street address.

  • Per item — one credit for each thing you ask about. =CDX.CITY over 500 ZIPs costs 500. Functions that look up live address or road data cost more per item: geocoding is 4, driving routes 3, address verification and census tracts 2.
  • Per row returned — RADIUS and ZIPLIST give you a list, so they are billed on the size of that list: 25 rows per credit, minimum 1. The same data looked up one ZIP at a time would cost 25× more — the list form is the bulk discount.
  • Per candidate searched — CLOSESTZIP returns only the closest few, but it has to search everything you hand it, so it is billed on the list you send: the same 25 per credit, minimum 1 (1,000 candidates = 40 credits). Measuring each one yourself with DISTANCE would cost 25× more.
  • Per driving grid — the Distance matrix tool with Method set to Driving charges 100 credits for each entry in the longer list, so a 500 × 400 grid is 50,000 credits (grids go up to 500 × 500). If either list has fewer than about 34 entries, or live traffic is on, the grid is priced per pair instead (3 credits a pair, 5 with live traffic). The tool always charges the lower price, and above 5 credits shows it for you to confirm before it runs.
  • …and one surcharge, on addresses — a driving route, a road route optimization or a map can only use a street address by looking up its coordinates first, and that lookup is charged like any other geocode. A route between two ZIPs is 3; the same route between two street addresses is 3 plus two geocodes. A map is 3, plus one geocode for each pin given as a street address (up to 50 pins per map). Give ZIPs, postal codes or "lat,lng" wherever you have them and nothing extra is charged. Straight-line ordering never pays it — it looks up no addresses at all.
  • One lookup, many fields — asking for several values from the same lookup costs one call, not several. =CDX.ROUTE(A1,B1,"distance_mi") and =CDX.ROUTE(A1,B1,"duration_min") in two cells are billed as a single route. The same is true of CLOSESTZIP, GEOCODE, REVGEOCODE and VERIFY.

Why a bigger radius barely costs more

Distance never affects the price — only the number of ZIPs that come back does.

  • =CDX.RADIUS("07869", 1) → ~4 ZIPs → 1 credit (the minimum)
  • =CDX.RADIUS("07869", 25) → ~60 ZIPs → 3 credits
  • =CDX.RADIUS("07869", 250) → ~2,500 ZIPs → 100 credits

A wide sweep over empty country returns few ZIPs and costs little; a small one over a dense metro can cost more. You pay for the data you receive.

  • Control the cost with the row limit — the last argument of RADIUS and ZIPLIST caps the rows, and therefore the charge. =CDX.RADIUS("07869", 250, , 100) costs 4 credits, not 100.
  • Repeats are free within a recalculation — identical lookups in the same recalculation are sent once. A column of =CDX.CITY over 500 rows covering 60 distinct ZIPs costs 60, not 500.
  • Failed lookups are not billed — a ZIP that doesn't exist, or an error on our side, costs nothing. It is still recorded, so your usage log shows the attempt at 0 credits.
  • The counter in the pane updates as formulas recalculate, and whenever you switch tabs or return to the pane. After a large fill-down it also shows what that recalculation just spent.
  • Running out — you are never billed for overage. When the balance is gone, calls stop with an out of credits message until you top up.
Loading function reference…

Contact support

Can't find what you need here? Our support team can help.

Go to support ↗