View Categories

How to Connect Google Analytics to Excel – Query Web Analytics with SQL

4 min read

Connect · GA4 to Excel

Get data from GA4 into Excel

Pull live rows from your GA4 account into Excel and refresh them whenever you like. No ODBC driver, no exports, no macros. About ten minutes the first time, and the Free plan covers it.

About 10 minutes No coding needed Credentials stay with you Excel anywhere, even on the web
Stuck at any point? Just ask us. Open Support in Query Streams (top-right menu → Support) and send us a message. Real people read it, and “I don’t know what this screen is asking for” is a perfectly good question.

What you’ll end up with

Google Analytics 4 logoA worksheet showing the live results of a SQL query against your GA4 account, with a button that pulls the latest rows whenever the data changes. Like this:

Google Analytics 4 holds your data behind its API. Getting it into Excel usually means exporting a CSV from the GA4 dashboard every time you need fresh numbers. Query Streams skips that: a small helper program called the Agent runs the query where your data is, and an Excel add-in asks it for the rows you want. Only the results travel, over an encrypted link, and Excel can be anywhere: your laptop at home, a colleague’s machine across the country, or Excel on the web.

WHERE THE AGENT RUNSany always-on computer or server with internetYour GA4 accountkeys stay hereQuery Streams Agentholds the credentialsQuery Streamsencrypted linkover the internet · results onlyWHEREVER YOU AREyour laptop, another office, a hotel, your phoneExcelWindows, Mac, or Excel on the web
The Agent lives with your data. Excel does not have to. Open the sheet anywhere and the rows come to you.

What you’ll need

A Query Streams account

The Free plan is enough for this guide. Sign up at my.querystreams.com.

The Agent on any always-on computer

A small program that runs in the background and calls GA4 when Excel asks. It just needs internet access.

Your GA4 login

You will sign in to GA4 once and allow read access. No passwords are typed into Query Streams.

Which computer gets the Agent? Any always-on machine that can already reach your GA4 account. Excel can be anywhere, including Excel on the web.

Connect it in five steps

  1. Create your account

    Go to my.querystreams.com and sign up. Pick the Free plan. It is a real plan, not a trial, and it covers connecting your GA4 account and running queries from Excel.

  2. Install the Agent on any always-on computer

    Sign in, open Download, and install the Agent on any always-on computer or server with internet access. It takes a minute and starts on its own from then on.

    Why a small program instead of a driver? The Agent is one install for Windows, Mac or Linux (about 85 MB on Windows, a little over 100 MB on Mac and Linux) that runs quietly in the background. It makes one outbound, encrypted connection to Query Streams, the same way a browser does, so you open no firewall port and set up no VPN. Your keys stay on that machine, and the rows travel to wherever you are, across the internet if need be. The only thing on your side is the add-in.

    The Download page shows Your Access Key. Paste it into the Agent when it asks, and wait for the badge to read Connected to Query Streams. That is the only thing you do on the Agent itself.

    Full walkthroughs if you want them: Windows, Mac, Linux.

  3. Point it at your GA4 account

    Back in your browser, open Data Agents (under Data in the top menu). Your Agent is listed there. Click Add connector, choose Google Analytics 4, and fill in the details you gathered earlier:

    Connection name
    Any name you will recognise later, like Sales database.
    Service Account JSON Key
    Paste the contents of the key file for a Google service account that has been added as a viewer on your GA4 property.
    GA4 Property ID
    The number that identifies your GA4 property, found in GA4 Admin under Property settings, like 486480978.

    Click Test connection. When it reads Connected, click Save. The connection reaches your Agent within a few seconds.

    Test failed? Usually an expired login or a missing permission. Sign in to GA4 directly with the same account and check it can see the data.

  4. Add Query Streams to Excel

    In Excel, go to Insert → Get Add-ins, search for Query Streams, and click Add. Or open it straight from Query Streams on Microsoft AppSource. A Query Streams button appears on the ribbon. Sign in with the same account.

    Works in Excel for Microsoft 365 on Windows and Mac, and in Excel on the web.

  5. Pull in your first table

    Click the Query Streams button, choose Stream a Query, and pick the connection you just made.

    Type the query you want to run. This one pulls a few columns from a ga4.traffic_overview table:

    Example · SQL
    SELECT date, sessions, total_users, screen_page_views
    FROM ga4.traffic_overview
    ORDER BY date DESC
    LIMIT 100;

    Under Destination Sheet choose Create a new sheet, then press the play button (the ▶ arrow). The rows land in Excel in a second or two. Press it again any time the data has changed and the sheet updates in place.

    Don’t know SQL? Build the query in the Query Streams portal instead. Query Builder shows your tables and columns so you can point and click. On Business plans you can also ask Nova in plain English (“show me customers in the USA”) and it writes the SQL for you. Save the query and it is one click away in the portal, and in the add-in’s Saved Queries list from Personal Core up.

That’s it. Your data is in the sheet and stays current with one click. Nothing left your network except the rows you asked for.

Good next moves

  • Save the query in the portal so you can run it again with one click, from Excel or Google Sheets.
  • Add a filter such as a date range, so the same query can answer “this month” without editing.
  • Share the results with a colleague. They see the rows, not your credentials.

Questions people ask

Does Excel have to be on the same computer as your GA4 account?

No. Only the Agent has to be where your GA4 account is. Excel can be on any computer with an internet connection, including Excel on the web and Excel on a Mac. Sign in to the add-in with your account and your connections are there.

Does my data get copied to Query Streams?

No. The Agent runs the query where your data is and sends only the rows it returns. Nothing is synced or stored in between.

Does the Free plan really cover this?

Yes. Free is a plan you keep, not a trial that expires. See exactly what it includes on the pricing page.

Does it work with Excel for Mac?

Yes. Excel for Microsoft 365 on Mac and Windows, and Excel on the web.

Still stuck? Open Support in Query Streams and tell us which step you are on and what you see. We will get you connected.
Query Streams also connects the same data toGoogle SheetsClaude, Cursor and ChatGPTa REST APIand more

Every guide for GA4

Not quite your setup?

  • Want to query the Excel workbooks themselves? Excel Folder reads a folder of workbooks as tables → Excel Folder
  • Want the Google searches that bring people to your site, with clicks and impressions? Google Search Console has them → Search Console
Updated on September 30, 2026

Powered by BetterDocs