Skip to content

Daily

Export Meta Ads results to Google Sheets every day

Every morning yesterday's spend, clicks and conversions for each campaign are added to your sheet, and you get a short summary by email.

Runs
Daily
Apps
Facebook Pages, Google Sheets
AI
Not needed
Access
ads_read; Sheet edit

Send this to your assistant

Create a ClickRuntime automation: every morning at 7, get yesterday's Meta Ads spend, impressions, clicks and conversions per campaign, add them to my Ads sheet, and email me the totals.

Paste it into your assistant. It tells you what it will send or change before it runs live.

First time? Adding ClickRuntime to your assistant takes about two minutes.

Why use it

Why teams use this automation

An online shop owner runs a handful of Meta ad campaigns and checks Ads Manager on their phone now and then. They can't easily compare this month with last, share numbers with their accountant, or spot when a campaign quietly started costing more.

Yesterday's results are now added to a sheet every morning, one row per campaign. Over a few weeks the sheet becomes a clear history that can be charted, shared and compared, and a short email gives the totals at a glance.

What you get out of it

  • A history you own

    Daily rows build into a record you can chart, filter and keep, independent of Ads Manager's views.

  • Easy to share

    Send the sheet to a partner or accountant without giving them access to your ad account.

  • Spot cost creep early

    Seeing cost per result day by day makes a slow rise obvious.

  • Totals in your inbox

    A short email each morning tells you yesterday's spend and results without opening anything.

How it works

What happens, step by step

  1. Every morning, ClickRuntime asks Meta for yesterday's results for each of your campaigns.

  2. It adds one row per campaign to your sheet with the date and the numbers.

  3. It adds up the day's totals across campaigns.

  4. You get a short email with yesterday's spend, clicks and conversions.

Before it runs live

  • Connect Facebook Pages
  • Connect your Google Sheets account and pick the spreadsheets it may use

What you get

RunsDaily
Export Meta Ads results to Google Sheets every daytoday, 9:00Succeeded
Email · Yesterday's Meta AdsSpend 184.20, clicks 912, conversions 23 across 4 campaigns.

Build your own

Need it to work differently?

This template is a starting point. Copy the prompt and change it, or describe a different automation from scratch, with your own conditions, more apps or an AI step. Your assistant writes it, tests it and runs it on ClickRuntime.
  • Your own rules

    Conditions, thresholds, filters and exceptions, written the way you'd explain them to a colleague.

  • Any number of apps

    One automation can read from one app and update several others. Over 248 apps are ready, and anything with an API works too.

  • AI where it helps

    Summaries, classification, extraction and drafts use ClickRuntime's built-in AI, with no extra key.

  • On a schedule or on each event

    Runs as often as every 5 minutes, or the moment an app sends an event, and keeps track of what it already handled.

Changes you can ask for

  • Run it at a different time, more or less often, or only on weekdays
  • Add an AI step, for example to summarize, sort or draft a reply
  • Add another app, for example also send it to Slack
  • Combine it with other Facebook Pages and Google Sheets steps into one automation

Under the hood

The code that runs this automation

This is the Python script that runs each time the automation starts. Your AI assistant writes it for you when you send the prompt, and you allow each step in your assistant. To change how the automation works, describe the change to your assistant and it updates the script for you. For every function it can use, see the script reference.
meta_ads_insights_into_google_sheets.pyexample
from google.oauth2.credentials import Credentials
from googleapiclient.discovery import build
from clickruntime import on_trigger, credentials, http, notify

AD_ACCOUNT, SHEET_ID = "act_1234567890", "your-spreadsheet-id"

@on_trigger
def run(event):
    data = http.get(f"https://graph.facebook.com/v21.0/{AD_ACCOUNT}/insights",
                    params={"level": "campaign", "date_preset": "yesterday", "access_token": credentials.connection("facebook", "work"),
                            "fields": "date_start,campaign_name,spend,impressions,clicks,actions"}).json()["data"]
    rows = []
    for d in data:
        conv = sum(int(a["value"]) for a in d.get("actions", []) if a["action_type"] == "purchase")
        rows.append([d["date_start"], d["campaign_name"], float(d["spend"]), int(d["impressions"]), int(d["clicks"]), conv])
    if rows:
        sheets = build("sheets", "v4", credentials=Credentials(credentials.connection("google", "work")), cache_discovery=False)
        sheets.spreadsheets().values().append(spreadsheetId=SHEET_ID, range="Ads!A:F", valueInputOption="USER_ENTERED",
                                              body={"values": rows}).execute()
    spend, clicks, conv = (sum(r[i] for r in rows) for i in (2, 4, 5))
    notify.email_me("Yesterday's Meta Ads", f"Spend {spend:.2f}, clicks {clicks}, conversions {conv} across {len(rows)} campaigns.")
    return {"campaigns": len(rows)}

FAQ

Common questions

Which numbers are logged?
Spend, impressions, clicks, conversions and cost per conversion for each campaign. You can add other metrics Meta reports, such as reach.
Can it log several ad accounts?
Yes. List the ad accounts in the prompt, and each row records which account it came from.
Does it change my ads?
No. It only reads results, so it can't pause, edit or spend anything.
What permissions does it need?
ads_read; Sheet edit. Nothing else in your accounts is used.
Does it need AI?
No. It runs without AI, so it doesn't use your plan's AI allowance.
How many runs does it use?
One run each time it runs (daily). Checks that find nothing to do and stop right away aren't counted.
Can I change how it works?
Yes. Describe the change to your AI assistant, for example a different schedule, channel or filter. It updates the automation, tests it and tells you what changed.

Set up “Export Meta Ads results to Google Sheets every day” from your assistant

Copy the prompt above, or connect your assistant first. Free plan, no credit card.