Copy-paste recipes for the 6-7 reports every site owner actually wants: DAU/MAU/WAU, retention cohort, top pages by source, channel attribution, conversion funnel, geo breakdown, device split.

MITAuto-check passed

Install Ga4 Common Reports

skills CLI
$ npx skills add jeremylongshore/tons-of-skills-marketplace --skill ga4-common-reports -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install jeremylongshore/tons-of-skills-marketplace ga4-common-reports --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/jeremylongshore/tons-of-skills-marketplace.git skills-src && mkdir -p .claude/skills && cp -r skills-src/plugins/saas-packs/ga4-pack/skills/ga4-common-reports .claude/skills/ga4-common-reports && rm -rf skills-src

Use ~/.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/

Facts

Skill name
ga4-common-reports
GitHub stars
2.8k
Token cost
~2.5k tokens
SKILL.md length
617 words
Files
1
Skills in repo
3,342
Repo updated
First seen
Licence
MIT

At a glance

Copy-paste recipes for the 6-7 reports every site owner actually wants: DAU/MAU/WAU, retention cohort, top pages by source, channel attribution, conversion funnel, geo breakdown, device split.

  • Works in 7 steps: Daily Active Users (DAU) — 30-day rolling → MAU / WAU — rolling unique users → Top pages — last 7 days, ordered by… → …
  • GA4 channel report
  • SKILL.md covers Overview, Prerequisites, Instructions and Examples, plus 12 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Ga4 Common Reports is an agent skill from jeremylongshore/tons-of-skills-marketplace. Copy-paste recipes for the 6-7 reports every site owner actually wants: DAU/MAU/WAU, retention cohort, top pages by source, channel attribution, conversion funnel, geo breakdown, device split. Each recipe is a fully-formed Data API request. Trigger with "GA4 DAU", "GA4 retention", "GA4 top pages", "GA4 funnel", "GA4 channel report", "common GA4 reports".

Its SKILL.md is about 2.5k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts. Compatibility notes: Designed for Claude Code

It works with Google Analytics. The repository describes itself as: Model-agnostic agent-skills platform with a harness-free canonical layer, verified adapters, and the ccpi package manager. Explore at tonsofskills.com. The licence is MIT.

When your agent uses it

  • GA4 channel report
  • Common GA4 reports

Example prompts

  • “GA4 DAU”
  • “GA4 retention”
  • “GA4 top pages”
  • “/ga4-common-reports”

Requirements

  • Python 3
  • Compatibility (from SKILL.md): Designed for Claude Code
  • Pre-approved tools (allowed-tools): Bash(python3:*)

Workflow steps

7 steps, taken from the step headings in SKILL.md.

  1. Daily Active Users (DAU) — 30-day rolling
  2. MAU / WAU — rolling unique users
  3. Top pages — last 7 days, ordered by pageviews
  4. Channel attribution — where did users come from?
  5. Retention cohort — week 1 / 2 / 3 / 4 return rate
  6. Conversion funnel — landing → engagement → conversion
  7. Geo + device split

What it can do on your machine

Read from SKILL.md and the folder at commit cfae287. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves these tools, so the agent can use them without asking each time:

    • Bash(python3:*)

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are python).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Links to these hosts (documentation or services it may open):

    • developers.google.com

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

  • Compatibility

    Designed for Claude Code

    From compatibility in the SKILL.md frontmatter.

Context cost

Ga4 Common Reports loads about 2.5k tokens when it runs. Until then it costs about 94 tokens; SKILL.md has 617 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~94
When it runs · the whole SKILL.md, loaded when a task matches
~2.5k

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.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

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); files beside SKILL.md are not scanned.

SKILL.md

The full file from jeremylongshore/tons-of-skills-marketplace at commit cfae287, republished under its MIT licence (© jeremylongshore). 617 words, ~2,522 tokens.

Download SKILL.mdSave it as .claude/skills/ga4-common-reports/SKILL.md (or your agent's skills folder).
name
ga4-common-reports
description
Copy-paste recipes for the 6-7 reports every site owner actually wants: DAU/MAU/WAU, retention cohort, top pages by source, channel attribution, conversion funnel, geo breakdown, device split. Each recipe is a fully-formed Data API request. Trigger with "GA4 DAU", "GA4 retention", "GA4 top pages", "GA4 funnel", "GA4 channel report", "common GA4 reports".
allowed-tools
Bash(python3:*)
compatibility
Designed for Claude Code
version
1.3.0
license
MIT
author
Jeremy Longshore <jeremy@intentsolutions.io>
tags
saas, analytics, google-analytics, ga4, reports

GA4 Common Reports

Overview

Recipes for the reports that get asked for ~95% of the time. Each one is a complete runReport you can paste, change PROPERTY_ID, and run. Prerequisite: ga4-auth-setup done.

Prerequisites

  • A GA4 Data API credential configured by ga4-auth-setup and granted Viewer access to the target property.
  • Python with google-analytics-data installed and GA4_PROPERTY_ID set to the numeric property ID.
  • A clear reporting window; use completed days for stable comparisons.

Instructions

The setup block (same for every recipe):

python
import os
from google.analytics.data_v1beta import BetaAnalyticsDataClient
from google.analytics.data_v1beta.types import (
    RunReportRequest, DateRange, Metric, Dimension,
    FilterExpression, Filter, OrderBy,
)

PROPERTY = f"properties/{os.environ['GA4_PROPERTY_ID']}"
client = BetaAnalyticsDataClient()

Examples

1. Daily Active Users (DAU) — 30-day rolling

python
req = RunReportRequest(
    property=PROPERTY,
    date_ranges=[DateRange(start_date="30daysAgo", end_date="yesterday")],
    metrics=[Metric(name="activeUsers")],
    dimensions=[Dimension(name="date")],
    order_bys=[OrderBy(dimension=OrderBy.DimensionOrderBy(dimension_name="date"))],
)
resp = client.run_report(req)
for r in resp.rows:
    print(f"{r.dimension_values[0].value} {r.metric_values[0].value}")

Why yesterday, not today: today's number is incomplete and will keep climbing through the day. For a clean rolling DAU, end the window at yesterday.

2. MAU / WAU — rolling unique users

GA4 doesn't expose MAU as a single metric — you compute it from the same activeUsers rolled up over a wider date range. The trick: a single-row report with no date dimension returns the unique count over the entire window (de-duplicated across days).

python
# MAU (last 30 days)
mau = client.run_report(RunReportRequest(
    property=PROPERTY,
    date_ranges=[DateRange(start_date="29daysAgo", end_date="yesterday")],
    metrics=[Metric(name="activeUsers")],
))
mau_count = int(mau.rows[0].metric_values[0].value) if mau.rows else 0

# WAU (last 7 days)
wau = client.run_report(RunReportRequest(
    property=PROPERTY,
    date_ranges=[DateRange(start_date="6daysAgo", end_date="yesterday")],
    metrics=[Metric(name="activeUsers")],
))
wau_count = int(wau.rows[0].metric_values[0].value) if wau.rows else 0

print(f"MAU: {mau_count:,}   WAU: {wau_count:,}   Ratio (engagement): {wau_count/mau_count:.2%}")

Stickiness rule-of-thumb: WAU/MAU > 0.5 is good, > 0.7 is excellent, < 0.2 means most users visit once and bounce.

3. Top pages — last 7 days, ordered by pageviews

python
req = RunReportRequest(
    property=PROPERTY,
    date_ranges=[DateRange(start_date="7daysAgo", end_date="yesterday")],
    metrics=[Metric(name="screenPageViews"), Metric(name="activeUsers"), Metric(name="averageSessionDuration")],
    dimensions=[Dimension(name="pagePath")],
    order_bys=[OrderBy(metric=OrderBy.MetricOrderBy(metric_name="screenPageViews"), desc=True)],
    limit=25,
)
resp = client.run_report(req)
print(f"{'Path':<60} {'Views':>8} {'Users':>8} {'AvgSec':>8}")
for r in resp.rows:
    print(f"{r.dimension_values[0].value[:58]:<60} "
          f"{r.metric_values[0].value:>8} {r.metric_values[1].value:>8} "
          f"{float(r.metric_values[2].value):>8.1f}")

4. Channel attribution — where did users come from?

python
req = RunReportRequest(
    property=PROPERTY,
    date_ranges=[DateRange(start_date="30daysAgo", end_date="yesterday")],
    metrics=[Metric(name="activeUsers"), Metric(name="sessions"), Metric(name="engagedSessions")],
    dimensions=[Dimension(name="sessionDefaultChannelGrouping")],
    order_bys=[OrderBy(metric=OrderBy.MetricOrderBy(metric_name="activeUsers"), desc=True)],
)
resp = client.run_report(req)
print(f"{'Channel':<28} {'Users':>10} {'Sessions':>10} {'Engaged%':>10}")
for r in resp.rows:
    users = int(r.metric_values[0].value)
    sess = int(r.metric_values[1].value)
    eng = int(r.metric_values[2].value)
    eng_rate = eng / sess if sess else 0
    print(f"{r.dimension_values[0].value:<28} {users:>10,} {sess:>10,} {eng_rate:>9.1%}")

GA4's default channel grouping has ~12 buckets: Direct, Organic Search, Paid Search, Organic Social, Paid Social, Email, Referral, Display, Video, Affiliates, Audio, etc. Use sessionSource + sessionMedium for finer-grained attribution (e.g. google / organic vs bing / organic).

5. Retention cohort — week 1 / 2 / 3 / 4 return rate

GA4 has a built-in cohort exploration in the UI but the Data API doesn't expose it cleanly. The workaround: query DAU per week and compute rolling overlap. The cheap approximation:

python
# Weekly active users for the last 8 weeks
req = RunReportRequest(
    property=PROPERTY,
    date_ranges=[DateRange(start_date="56daysAgo", end_date="yesterday")],
    metrics=[Metric(name="activeUsers")],
    dimensions=[Dimension(name="isoYearIsoWeek")],
    order_bys=[OrderBy(dimension=OrderBy.DimensionOrderBy(dimension_name="isoYearIsoWeek"))],
)
resp = client.run_report(req)
for r in resp.rows:
    print(f"{r.dimension_values[0].value}  {r.metric_values[0].value}")

For true cohort retention (e.g. "of users acquired in week N, what % came back in week N+1, N+2, N+3"), you need event-level data — use ga4-bigquery-export and write the cohort SQL directly. The Data API can't express the join.

6. Conversion funnel — landing → engagement → conversion

GA4 funnels via API: query each step as a separate runReport filtered by the event that defines the step, then divide.

python
def step_users(event_name, days_ago=7):
    return int(client.run_report(RunReportRequest(
        property=PROPERTY,
        date_ranges=[DateRange(start_date=f"{days_ago}daysAgo", end_date="yesterday")],
        metrics=[Metric(name="activeUsers")],
        dimension_filter=FilterExpression(filter=Filter(
            field_name="eventName",
            string_filter=Filter.StringFilter(
                match_type=Filter.StringFilter.MatchType.EXACT,
                value=event_name,
            ),
        )),
    )).rows[0].metric_values[0].value)

# Example funnel: landed → engaged → signed up → purchased
steps = [
    ("session_start",  step_users("session_start")),
    ("user_engagement", step_users("user_engagement")),
    ("sign_up",         step_users("sign_up")),
    ("purchase",        step_users("purchase")),
]
top = steps[0][1] or 1
print(f"{'Step':<20} {'Users':>10} {'% of top':>10}")
for name, count in steps:
    print(f"{name:<20} {count:>10,} {count/top:>9.1%}")

Limitation: this counts users who fired the event at any point in the window, NOT users who progressed through the funnel in order. For ordered funnels (true sequencing), use BigQuery export or the GA4 UI's Exploration → Funnel report.

Show full SKILL.md (245 more words)Show less

7. Geo + device split

python
req = RunReportRequest(
    property=PROPERTY,
    date_ranges=[DateRange(start_date="30daysAgo", end_date="yesterday")],
    metrics=[Metric(name="activeUsers"), Metric(name="bounceRate")],
    dimensions=[Dimension(name="country"), Dimension(name="deviceCategory")],
    order_bys=[OrderBy(metric=OrderBy.MetricOrderBy(metric_name="activeUsers"), desc=True)],
    limit=30,
)
resp = client.run_report(req)
for r in resp.rows:
    country, device = r.dimension_values[0].value, r.dimension_values[1].value
    users, bounce = r.metric_values[0].value, float(r.metric_values[1].value)
    print(f"{country:<20} {device:<10} {users:>10} {bounce:>6.1%}")

A common signal: if one country dominates with low engagement + high bounce, it's often bot traffic from that country's cloud-host hubs (Singapore, Vietnam, China data centers are the usual suspects).

Output

Each recipe prints a focused, ready-to-inspect report: date-series users, aggregate MAU/WAU, ranked pages or channels, a funnel, or geo/device rows. The results are API aggregates and should be interpreted with the date window and metric definitions shown in each recipe.

Error Handling

If a request fails, first confirm that the property ID is numeric, the credential has property access, and the metric/dimension pair is valid. Empty reports can be legitimate for an inactive property or a future/incomplete date range; use ga4-data-api-query to check compatibility and pagination before assuming data loss.

Resources

  • GA4 Data API reference — metric, dimension, and request documentation.
  • ga4-bigquery-export — the companion skill for event-level analysis and unsampled cohort queries.

When the Data API isn't enough

Three reasons to graduate to BigQuery export:

  1. Sampling — your queries hit resp.metadata.data_loss_from_other_row=True. Sampled = approximate. BQ export = exact.
  2. Custom event analytics — joining event-level data across sessions, computing retention cohorts, building attribution models. SQL is the only sensible tool.
  3. Cost — Data API has daily quotas; BQ is pay-per-query (free for small properties, cheap up to ~100M events/day).

See ga4-bigquery-export for the setup.

  • ga4-auth-setup — prerequisite
  • ga4-data-api-query — the underlying API the recipes here use
  • ga4-realtime-api — for "right now" data instead of any of the above
  • ga4-bigquery-export — when these recipes hit their limits

© jeremylongshore, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in plugins/saas-packs/ga4-pack/skills/ga4-common-reports of jeremylongshore/tons-of-skills-marketplace.

Open the folder on GitHubat commit cfae287

Compare with similar skills

Ga4 Common Reports 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.

Ga4 Common Reports compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Ga4 Common Reports this skilljeremylongshore/tons-of-skills-marketplace2.8k—~2.5kAutomated safety check: PassMIT
Google SEO APIsAgriciDaniel/claude-seo19k1 repos~4.2kAutomated safety check: PassMIT
AnalyticsNexus-JPF/note-companion8707 repos~2.2kAutomated safety check: PassMIT
Blog GoogleAgriciDaniel/claude-blog2.3k1 repos~3.3kAutomated safety check: NotesMIT
SEO GoogleAgriciDaniel/codex-seo7992 repos~3.4kAutomated safety check: PassMIT
C15tc15t/c15t1.9k1 repos~1.6kAutomated safety check: PassApache-2.0

Similar skills

  • 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.

    19k GitHub starsUsed in 1 repo~4.2k tokens
    Marketing & SEOAuto-check passed
  • Analytics

    Nexus-JPF/note-companion

    When the user wants to set up, improve, or audit analytics tracking and measurement.

    870 GitHub starsUsed in 7 repos~2.2k tokens
    Marketing & SEOAuto-check passed
  • Blog Google

    AgriciDaniel/claude-blog

    Google API integration for blog performance: PageSpeed Insights, CrUX Core Web Vitals with 25-week history, Search Console performance, URL Inspection, Indexing API, GA4 organic traffic, NLP entity…

    2.3k GitHub starsUsed in 1 repo~3.3k tokens
    Marketing & SEOAuto-check: notes
  • SEO Google

    AgriciDaniel/codex-seo

    Google SEO APIs: Search Console (Search Analytics, URL Inspection, Sitemaps), PageSpeed Insights v5, CrUX field data with 25-week history, Indexing API v3, and GA4 organic traffic.

    799 GitHub starsUsed in 2 repos~3.4k tokens
    Frontend & DesignAuto-check passed
  • C15t

    c15t/c15t

    Work with c15t consent management docs, APIs, and integrations for Next.js, React, and JavaScript.

    1.9k GitHub starsUsed in 1 repo~1.6k tokens
    Legal & ComplianceAuto-check passed
  • AI Visibility

    Ryze-AI-Adgent/open-seo-mcp-skills

    Measure real AI-engine visibility — traffic from ChatGPT, Perplexity, Claude, Gemini and which pages they cite — from actual GA4 referral data, not prompt sampling.

    4.7k GitHub stars~611 tokensUpdated 17 days ago
    Marketing & SEOAuto-check passed

More from jeremylongshore/tons-of-skills-marketplace

All 3,342 skills in this repo
  • Performing Security Code Review

    jeremylongshore/tons-of-skills-marketplace

    Execute this skill enables AI assistant to conduct a security-focused code review using the security-agent plugin.

    2.8k GitHub starsUsed in 2 repos~1.3k tokens
    Auto-check: notes
  • Adapting Transfer Learning Models

    jeremylongshore/tons-of-skills-marketplace

    Build this skill automates the adaptation of pre-trained machine learning models using transfer learning techniques.

    2.8k GitHub stars~1.1k tokensUpdated today
    Auto-check passed
  • Agent Context Loader

    jeremylongshore/tons-of-skills-marketplace

    Execute proactive auto-loading: automatically detects and loads agents.md files.

    2.8k GitHub stars~1.1k tokensUpdated today
    Auto-check passed
  • Aggregating Performance Metrics

    jeremylongshore/tons-of-skills-marketplace

    Aggregate and centralize performance metrics from applications, systems, databases, caches, and services.

    2.8k GitHub stars~1.2k tokensUpdated today
    Auto-check passed
  • Analyzing Capacity Planning

    jeremylongshore/tons-of-skills-marketplace

    Execute this skill enables AI assistant to analyze capacity requirements and plan for future growth.

    2.8k GitHub stars~947 tokensUpdated today
    Auto-check passed
  • Analyzing Database Indexes

    jeremylongshore/tons-of-skills-marketplace

    Process use when you need to work with database indexing. An agent skill from jeremylongshore/tons-of-skills-marketplace.

    2.8k GitHub stars~2k tokensUpdated today
    Auto-check passed

Questions about Ga4 Common Reports

What does Ga4 Common Reports do?

Copy-paste recipes for the 6-7 reports every site owner actually wants: DAU/MAU/WAU, retention cohort, top pages by source, channel attribution, conversion funnel, geo breakdown, device split. Ga4 Common Reports is an agent skill from jeremylongshore/tons-of-skills-marketplace. Copy-paste recipes for the 6-7 reports every site owner actually wants: DAU/MAU/WAU, retention cohort, top pages by source, channel attribution, conversion funnel, geo breakdown, device split.

When should I use Ga4 Common Reports?

Ga4 Common Reports fits situations like: GA4 channel report; common GA4 reports.

How do I install Ga4 Common Reports in Claude Code?

Run `npx skills add jeremylongshore/tons-of-skills-marketplace --skill ga4-common-reports -a claude-code`. Or copy the skill folder (plugins/saas-packs/ga4-pack/skills/ga4-common-reports in jeremylongshore/tons-of-skills-marketplace) into .claude/skills/ga4-common-reports in your project. Claude Code loads it when a task matches its description.

How do I install Ga4 Common Reports in Codex?

Run `npx skills add jeremylongshore/tons-of-skills-marketplace --skill ga4-common-reports -a codex`. Or copy the skill folder (plugins/saas-packs/ga4-pack/skills/ga4-common-reports in jeremylongshore/tons-of-skills-marketplace) into .agents/skills/ga4-common-reports in your project. Codex loads it when a task matches its description.

Can I use Ga4 Common Reports in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add jeremylongshore/tons-of-skills-marketplace --skill ga4-common-reports -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/ga4-common-reports, .gemini/skills/ga4-common-reports, .github/skills/ga4-common-reports and .opencode/skills/ga4-common-reports in your project.

What does Ga4 Common Reports need to run?

SKILL.md names no scripts, command-line tools or credentials: Ga4 Common Reports is instructions for the agent only. Our summary lists: Python 3. Its frontmatter pre-approves these tools: Bash(python3:*). Compatibility (from SKILL.md): Designed for Claude Code.

Does Ga4 Common Reports access the network?

SKILL.md names 1 domain. As links in the text: developers.google.com. This is read from the text; nothing was executed.

Is Ga4 Common Reports safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Ga4 Common Reports use?

Ga4 Common Reports is published under the MIT licence (declared in SKILL.md). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Ga4 Common Reports use?

About 2.5k tokens (SKILL.md is roughly 10k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Ga4 Common Reports?

Skills that share tags, products or a category with Ga4 Common Reports: Google SEO APIs (AgriciDaniel/claude-seo, 19k stars), Analytics (Nexus-JPF/note-companion, 870 stars), Blog Google (AgriciDaniel/claude-blog, 2.3k stars) and SEO Google (AgriciDaniel/codex-seo, 799 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Ga4 Common Reports?

jeremylongshore (a GitHub user) maintains it in jeremylongshore/tons-of-skills-marketplace, which has 2,827 GitHub stars. The repository holds 3,342 skills in this directory. The repository was last updated on October 10, 2026.

Source: jeremylongshore/tons-of-skills-marketplace on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.