Google SEO APIs
AgriciDaniel/claude-seo
Pulls real Google data for SEO work: Search Console, PageSpeed Insights, CrUX field data, the Indexing API and GA4 organic traffic, through /seo google commands.
Pulls Google Analytics 4 data through the Data API with TypeScript scripts and turns it into a daily SEO report or prioritized traffic and bounce-rate recommendations.
$ npx skills add LichAmnesia/lich-skills --skill google-analytics -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install LichAmnesia/lich-skills google-analytics --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/LichAmnesia/lich-skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/google-analytics .claude/skills/google-analytics && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "google-analytics" agent skill from https://github.com/LichAmnesia/lich-skills/tree/main/skills/google-analytics into .claude/skills/google-analytics/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "google-analytics", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/LichAmnesia/lich-skills/tree/main/skills/google-analyticsType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add LichAmnesia/lich-skills --skill google-analytics -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install LichAmnesia/lich-skills google-analytics --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/LichAmnesia/lich-skills.git skills-src && mkdir -p .agents/skills && cp -r skills-src/skills/google-analytics .agents/skills/google-analytics && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "google-analytics" agent skill from https://github.com/LichAmnesia/lich-skills/tree/main/skills/google-analytics into .agents/skills/google-analytics/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "google-analytics", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add LichAmnesia/lich-skills --skill google-analytics -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install LichAmnesia/lich-skills google-analytics --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/LichAmnesia/lich-skills.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/skills/google-analytics .cursor/skills/google-analytics && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "google-analytics" agent skill from https://github.com/LichAmnesia/lich-skills/tree/main/skills/google-analytics into .cursor/skills/google-analytics/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "google-analytics", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/LichAmnesia/lich-skills.git --path skills/google-analytics--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add LichAmnesia/lich-skills --skill google-analytics -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install LichAmnesia/lich-skills google-analytics --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/LichAmnesia/lich-skills.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/skills/google-analytics .gemini/skills/google-analytics && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "google-analytics" agent skill from https://github.com/LichAmnesia/lich-skills/tree/main/skills/google-analytics into .gemini/skills/google-analytics/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "google-analytics", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install LichAmnesia/lich-skills google-analyticsInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add LichAmnesia/lich-skills --skill google-analytics -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/LichAmnesia/lich-skills.git skills-src && mkdir -p .github/skills && cp -r skills-src/skills/google-analytics .github/skills/google-analytics && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "google-analytics" agent skill from https://github.com/LichAmnesia/lich-skills/tree/main/skills/google-analytics into .github/skills/google-analytics/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "google-analytics", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add LichAmnesia/lich-skills --skill google-analytics -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install LichAmnesia/lich-skills google-analytics --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/LichAmnesia/lich-skills.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/skills/google-analytics .opencode/skills/google-analytics && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "google-analytics" agent skill from https://github.com/LichAmnesia/lich-skills/tree/main/skills/google-analytics into .opencode/skills/google-analytics/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "google-analytics", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
google-analyticsPulls Google Analytics 4 data through the Data API with TypeScript scripts and turns it into a daily SEO report or prioritized traffic and bounce-rate recommendations.
The skill reads GA4 aggregates through the official Data API client using TypeScript scripts run with Bun or `npx tsx`. Its default, `daily-report.ts`, takes one property and produces an organic-search report with no setup beyond credentials, and can write JSON to a file. Other requests it handles include reviewing the last 30 days, finding top traffic sources and high-bounce pages, comparing months and diagnosing why mobile converts worse than desktop.
Setup needs a numeric `GOOGLE_ANALYTICS_PROPERTY_ID` and a `GOOGLE_APPLICATION_CREDENTIALS` path to a service account key, with the account given only the Viewer role, plus one dependency installed with `bun install` or npm. The key and `.env` must never be committed. The skill is read-only: it does not do real-time analytics, change GA configuration, audiences or events, or return individual-user data.
2 steps, taken from the step headings in SKILL.md.
Read from SKILL.md and the folder at commit ebbc355. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
Ships 4 files in scripts/ (TypeScript), which the agent can run.
Shell commands in SKILL.md call:
bunnpxnpmFrom the folder's file list and the shell code blocks in SKILL.md.
Links to these hosts (documentation or services it may open):
bun.shFrom URLs in SKILL.md, links to its own repository left out.
Names these keys or tokens, usually read from environment variables:
GOOGLE_APPLICATION_CREDENTIALSFrom names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Google Analytics 4 Analysis loads about 2k tokens when it runs. Until then it costs about 83 tokens; SKILL.md has 785 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check noted patterns worth knowing about, such as sudo or a known installer.
r copy [`.env.example`](.env.example) → `.env` (Bun auto-loads `.env`; under `tsx`, export the vars instead). Full servi**Never commit the JSON key or `.env`.** Store the key outside the repo; grant the service account only the **Viewer** rort` the env vars, since tsx won't read `.env`).- Credentials come from env vars / `.env` only — never hardcoded.Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); the scripts in this folder are not scanned.
The full file from LichAmnesia/lich-skills at commit ebbc355, republished under its MIT licence (© LichAmnesia). 785 words, ~2,025 tokens.
.claude/skills/google-analytics/SKILL.md (or your agent's skills folder). This skill also uses 7 other files; get the full folder from GitHub.Pull GA4 data via the Data API and turn it into actionable, prioritized recommendations. Scripts are TypeScript (run with Bun or npx tsx).
daily-report.ts (the out-of-the-box default)export GOOGLE_ANALYTICS_PROPERTY_ID="YOUR_PROPERTY_ID_HERE" # numeric, not the G- id
export GOOGLE_APPLICATION_CREDENTIALS="/path/to/service-account-key.json"Or copy .env.example → .env (Bun auto-loads .env; under tsx, export the vars instead). Full service-account walkthrough is inside .env.example.
Never commit the JSON key or .env. Store the key outside the repo; grant the service account only the Viewer role on the GA4 property.
cd skills/google-analytics/scripts
bun install # or: npm installThe only runtime dep is @google-analytics/data (official Google client, fully typed).
daily-report.ts — SEO daily report (out-of-the-box default) ⭐Point it at one property and get a complete, opinionated organic-search report — zero config beyond credentials. This is the SEO-expert default template.
bun run daily-report.ts --property 123456789 # one property → one report
bun run daily-report.ts # uses GOOGLE_ANALYTICS_PROPERTY_ID
bun run daily-report.ts --format json --output today.jsonDefault template (in order): Organic KPIs (rolling 28d vs prior 28d — the Search-Console 4-week-block convention that removes day-of-week skew) · daily anomaly check (yesterday vs same weekday last week, flags drops ≥ 25%) · organic trend sparkline · top organic landing pages (the SEO money view) · by search engine · by country · by device (mobile-first) · auto-generated prioritized recommendations. Everything is filtered to sessionDefaultChannelGroup = "Organic Search".
Flags: --property <id>, --days <n> (default 28), --channel <name> (default "Organic Search"), --anomaly-threshold <pct> (default 25), --format md|json (default md), --output FILE, --help. Writes seo-daily-<date>.md by default.
It auto-detects whether the property uses GA4's conversions or the newer keyEvents metric, and any single failing sub-query degrades gracefully instead of aborting the report.
GA4 limitation: GA4 has no keyword / impression / CTR / average-position data — that lives in Google Search Console (a different API). This report covers the organic behavior GA4 owns; pair with GSC for the query side.
ga-client.ts — raw report queryThin wrapper over runReport. Any metrics × dimensions combo.
# Last 30 days of sessions + users (JSON)
bun run ga-client.ts --days 30 --metrics sessions,users
# Top pages by views, table output
bun run ga-client.ts --days 7 --metrics screenPageViews \
--dimensions pagePath --order-by screenPageViews --limit 20 --format table
# Specific window, filtered by country
bun run ga-client.ts --start 2026-01-01 --end 2026-01-31 \
--metrics sessions,bounceRate --dimensions country --filter "country:United States"Flags: --days N | --start --end (YYYY-MM-DD or NdaysAgo/yesterday), --metrics (required, comma-sep), --dimensions, --limit (default 10), --order-by (prefix - desc / + asc), --filter "field:value", --format json|table, --output FILE.
analyze.ts — higher-level analysis + recommendationsPre-built analyses that return metrics plus prioritized recommendations.
bun run analyze.ts --analysis-type seo --days 28 # organic-only KPIs + top landing pages
bun run analyze.ts --analysis-type overview --days 30 # current vs previous period
bun run analyze.ts --analysis-type sources --days 30 # traffic sources + optimizations
bun run analyze.ts --analysis-type content --days 30 # high-bounce pages + diagnosis (all channels)
bun run analyze.ts --analysis-type devices --days 30 # mobile vs desktop gap (all channels)--output FILE writes JSON to disk instead of stdout. --channel <name> overrides the organic channel group for the seo cut.
Which report do I actually need? For SEO, reach for daily-report.ts first and --analysis-type seo for a quick organic snapshot. overview / sources are useful general cuts. content and devices are all-channel (not organic-only) and content keys off bounceRate (a de-emphasized GA4 metric) — keep them for general GA use, but for SEO the daily report's organic-filtered device/landing cuts supersede them.
No Bun? Swap
bun run X.ts→npx tsx X.tseverywhere (andexportthe env vars, since tsx won't read.env).
When the user asks an analytics question:
ga-client.ts; a "how are we doing / what should we fix" question → analyze.ts.See EXAMPLES.md for end-to-end question → command → analysis patterns, and REFERENCE.md for the full metric/dimension catalog.
The report is a single self-contained command, so any scheduler works. Two options:
Plain cron — write a dated report to a folder each morning (GA4 finalizes "yesterday" within ~24h, so an early-AM run is safe):
# crontab -e (8:00 every day) — adjust the absolute paths
0 8 * * * cd /path/to/skills/google-analytics/scripts && \
GOOGLE_ANALYTICS_PROPERTY_ID=123456789 \
GOOGLE_APPLICATION_CREDENTIALS=/secure/sa.json \
/usr/local/bin/bun run daily-report.ts --output "/reports/seo-$(date +\%F).md"Claude Code /schedule — schedule an agent that runs daily-report.ts, then reads the Markdown and messages you the 2-3 highest-priority recommendations (turns the raw report into a daily briefing). Ask: "schedule a daily 8am SEO report for property 123456789 and summarize the HIGH recommendations."
Either way: one property in → one report out, every day.
GOOGLE_APPLICATION_CREDENTIALS points at a valid JSON key, the service account has Viewer on the property, and GOOGLE_ANALYTICS_PROPERTY_ID is the numeric property ID (not the G-XXXX measurement ID).yesterday (not today) — today's data is incomplete.bun install (or npm install) inside scripts/..env only — never hardcoded.© LichAmnesia, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
SKILL.md and 7 other files (scripts) in skills/google-analytics of LichAmnesia/lich-skills.
Open the folder on GitHubat commit ebbc355
Google Analytics 4 Analysis next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Google Analytics 4 Analysis this skillLichAmnesia/lich-skills | 234 | — | ~2k | Automated safety check: Notes | MIT | |
| Google SEO APIsAgriciDaniel/claude-seo | 18k | 1 repos | ~4.2k | Automated safety check: Pass | MIT | |
| AnalyticsNexus-JPF/note-companion | 869 | 6 repos | ~2.2k | Automated safety check: Pass | MIT | |
| GEO Monthly Delta Reportzubair-trabzada/geo-seo-claude | 11k | — | ~2.4k | Automated safety check: Notes | MIT | |
| Analytics Trackingborghei/Claude-Skills | 874 | — | ~5.7k | Automated safety check: Pass | MIT | |
| Paid Social BriefOotto-AI/claude-content-skills | 101 | — | ~831 | Automated safety check: Pass | MIT |
AgriciDaniel/claude-seo
Pulls real Google data for SEO work: Search Console, PageSpeed Insights, CrUX field data, the Indexing API and GA4 organic traffic, through /seo google commands.
Nexus-JPF/note-companion
When the user wants to set up, improve, or audit analytics tracking and measurement.
zubair-trabzada/geo-seo-claude
Compares a baseline and a current GEO audit for a client, calculates score changes and action item progress, and writes a monthly progress report.
borghei/Claude-Skills
End-to-end analytics implementation for web and SaaS: GA4, Google Tag Manager, event taxonomy, conversion tracking, and UTM strategy.
Ootto-AI/claude-content-skills
A skill your agent uses when an approved social campaign needs a media-ready brief for paid distribution, creative testing, and measurement.
About-Intelligence/soku-cli
Guides an agent through the soku command line tool for ads, GA4 and PostHog data reads, ads writes, SEO hosting, automations, files and skill management.
LichAmnesia/lich-skills
Generates or edits PNG images with Google's Nano Banana 2 model through a small script, with a choice of 512, 1K, 2K or 4K output.
LichAmnesia/lich-skills
Organizes long-running agent work into a Project, Sprint and Task hierarchy with per-task state files, isolated worktrees, review loops and script-checked rules.
LichAmnesia/lich-skills
Runs headless web searches and single-page extraction through the Tavily API from a Python script, returning cited, summarized results without a browser.
LichAmnesia/lich-skills
Drives a failing build, typecheck, lint or test command to a passing exit code through small, one-fix-at-a-time rounds, stopping at a hard attempt cap instead of looping forever.
LichAmnesia/lich-skills
Replaces trial-and-error fixing with an observe, hypothesize, experiment and conclude loop kept in DEBUG.md, where no fix is allowed before evidence supports a cause.
LichAmnesia/lich-skills
Runs a gated Spec, Plan, Build, Test, Review, Ship workflow so non-trivial changes are specified, verified and reviewed before they ship, with a named artifact per phase.
Works with
Categories
Pulls Google Analytics 4 data through the Data API with TypeScript scripts and turns it into a daily SEO report or prioritized traffic and bounce-rate recommendations. The skill reads GA4 aggregates through the official Data API client using TypeScript scripts run with Bun or `npx tsx`.ts`, takes one property and produces an organic-search report with no setup beyond credentials, and can write JSON to a file.
Google Analytics 4 Analysis fits situations like: getting a daily SEO report for a GA4 property; finding top traffic sources, organic landing pages and high-bounce pages; comparing this month with last month; diagnosing why mobile conversion is lower than desktop.
Run `npx skills add LichAmnesia/lich-skills --skill google-analytics -a claude-code`. Or copy the skill folder (skills/google-analytics in LichAmnesia/lich-skills) into .claude/skills/google-analytics in your project. Claude Code loads it when a task matches its description.
Run `npx skills add LichAmnesia/lich-skills --skill google-analytics -a codex`. Or copy the skill folder (skills/google-analytics in LichAmnesia/lich-skills) into .agents/skills/google-analytics in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add LichAmnesia/lich-skills --skill google-analytics -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/google-analytics, .gemini/skills/google-analytics, .github/skills/google-analytics and .opencode/skills/google-analytics in your project.
Going by SKILL.md and its folder, Google Analytics 4 Analysis needs TypeScript for the scripts in its folder, the command-line tools its instructions call (bun, npx and npm) and credentials named GOOGLE_APPLICATION_CREDENTIALS. Our summary lists: A GA4 property ID; A Google service account key with Viewer access to the property; Bun, or Node.js with npx tsx.
SKILL.md names 1 domain. As links in the text: bun.sh. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found notes only (mentions a .env file), nothing it rates as a warning. It is not a guarantee. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.
Google Analytics 4 Analysis is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 2k tokens (SKILL.md is roughly 8.1k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Google Analytics 4 Analysis: Google SEO APIs (AgriciDaniel/claude-seo, 18k stars), Analytics (Nexus-JPF/note-companion, 869 stars), GEO Monthly Delta Report (zubair-trabzada/geo-seo-claude, 11k stars) and Analytics Tracking (borghei/Claude-Skills, 874 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
LichAmnesia (a GitHub user) maintains it in LichAmnesia/lich-skills, which has 234 GitHub stars. The repository holds 11 skills in this directory. The repository was last updated on June 9, 2026.
Source: LichAmnesia/lich-skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.