Search Term Archiver
Archives every month's search terms into your own Google Sheet — a permanent query warehouse for multi-year trend analysis that survives Google's data trimming, restructures and agency changes.
by Dmytro Tonkikh·chiliad.io
Overview
Google trims search term history and hides low-volume queries — what you can pull today is gone in two years. Search Term Archiver appends the last full month's search terms (with status, campaign, ad group, and full metrics) to a Google Sheet you own, once per month, never duplicating a month. Over time it becomes the asset Google won't give you: a multi-year query warehouse for long-horizon trend analysis, n-grams over years, and evidence that survives account restructures.
Setup
- 1Open your Google Ads account and go to Tools → Bulk Actions → Scripts.
- 2Click the + button to create a new script and paste the code below.
- 3Run once — the script creates the archive sheet and logs its URL. Put it into SPREADSHEET_URL.
- 4Schedule monthly (any day — it always archives the last complete month, exactly once).
Configuration Variables
| Variable | Default |
|---|---|
SPREADSHEET_URL | (empty) |
SHEET_NAME | archive |
MAX_ROWS_PER_MONTH | 20000 |
MIN_CLICKS | 1 |
Expected Output
=== Search Term Archiver === Archived 18342 search terms for 2026-06. Archive: https://docs.google.com/spreadsheets/d/...
Notes
At 20k rows/month × 10 columns, the sheet holds roughly 4 years before nearing Google Sheets' cell ceiling — start a second spreadsheet then, or lower the cap. The month-dedupe checks the last archived row, so runs are idempotent: schedule it and forget it. Analyze the archive with pivot tables or plug it into Looker Studio.