# AdSense

> AdSense is an open-source MCP server for analytics and data. Read-only MCP server that pulls Google AdSense earnings reports into AI clients. It is available on CLI and Self-hosted.

- **Kind:** MCP server
- **Pricing:** Open source
- **Platforms:** CLI, Self-hosted
- **Repository:** https://github.com/homielab/homielab-mcp/tree/HEAD/services/adsense
- **MCP Registry name:** io.github.homielab/adsense
- **Categories:** [analytics and data](https://ai-powered.com/categories/analytics-and-data)
- **Listing updated:** 2026-11-27

## About

Connects an AI assistant to a Google AdSense account so it can query earnings, page views, clicks and RPM broken down by site, page, ad unit, country, platform and more. Reports can be built from ready-made presets or specified in full, and results come back as markdown tables or CSV files.

The server is written in Go on the official MCP Go SDK and wraps the AdSense Management API v2. Sign-in happens once through a browser OAuth consent flow, and the token is stored locally. It requests only the read-only AdSense scope, so it cannot change anything in the account. Beyond reports, it lists sites, ad units, payments, alerts, policy issues and ad code.

It suits publishers and ad operations people who want to ask plain-language questions about revenue, compare periods, or get a full performance sweep without opening the AdSense dashboard. Setup requires a Google Cloud OAuth client and the mcp-homielab binary.

## Features

- **Ready-made report presets:** Run many breakdowns such as sites, pages, countries and daily totals in a single call.
- **Custom report builder:** Choose any dimensions, metrics, filters and sort order for a date range.
- **Period-over-period comparison:** Shows per-key changes against the preceding window of equal length, sorted by impact.
- **CSV export to file:** Writes large exports of up to a million rows straight to disk with a short preview.
- **Alerts and policy checks:** Lists active payment and policy alerts and violations per site.
- **Read-only access:** Requests only the read-only AdSense scope, so the account cannot be modified.

## Good for

- Get a monthly breakdown of earnings by site, page and country
- Find which ad unit or site lost the most earnings week over week
- Export daily earnings data to CSV for spreadsheet analysis
- Check account alerts and policy issues before a payment cycle
- Generate a written performance review with recommended actions

## Tools

From the tool list in its README, going by the names, 15 of 22 tools read data; 7 names don't say. From the server's own tool labels and tool names; not verified by us.

- `adsense_list_accounts` (name suggests: reads): Lists accessible AdSense accounts.
- `adsense_get_account` (name suggests: reads): Returns account details such as name, time zone and premium status.
- `adsense_preset_report`: Runs one or many ready-made reports in a single call.
- `adsense_generate_report`: Generates a custom report with markdown table and totals.
- `adsense_generate_report_csv`: Generates a raw CSV report of up to 1,000,000 rows.
- `adsense_period_comparison`: Compares a report across the current and preceding windows.
- `adsense_list_sites` (name suggests: reads): Lists registered sites with review state and auto-ads.
- `adsense_list_ad_units` (name suggests: reads): Lists ad units of the content ad client.
- `adsense_list_saved_reports` (name suggests: reads): Lists reports saved in the AdSense UI.
- `adsense_generate_saved_report`: Runs a saved report with an optional date range and CSV output.
- `adsense_list_payments` (name suggests: reads): Lists payment records.
- `adsense_list_alerts` (name suggests: reads): Lists active policy and payment alerts.
- `adsense_list_policy_issues` (name suggests: reads): Lists policy violations per site.
- `adsense_list_channels` (name suggests: reads): Lists custom and URL channels.
- `adsense_get_ad_code` (name suggests: reads): Returns the HTML ad code for an ad unit or account-wide.
- `adsense_get_ad_blocking_recovery_tag` (name suggests: reads): Returns the ad-blocking recovery tag script.
- `adsense_list_child_accounts` (name suggests: reads): Lists sub-accounts.
- `adsense_list_ad_clients` (name suggests: reads): Lists ad clients.
- `adsense_list_channel_links` (name suggests: reads): Lists ad unit and custom channel memberships.
- `adsense_login`: Starts the OAuth consent flow in the browser.
- `adsense_login_status` (name suggests: reads): Reports the state of the login flow and token.
- `adsense_logout`: Deletes the stored token.

## FAQ

### Can it change settings or ad units in my AdSense account?

No. It requests only the read-only scope and does not include methods that create or modify ad units or channels.

### How do I authorize the server?

Create a Google Cloud OAuth desktop client, enable the AdSense Management API, then run the login command or the adsense_login tool and approve in the browser.

### What happens if a report combination is rejected by the API?

That preset is reported inline with the error and the other presets in the same call still run.

### How are rate limits and failures handled?

Requests time out after 90 seconds and are retried up to three times with backoff on rate limits, server errors and network problems, but not on client errors.

### Is AdSense free?

Yes. AdSense is open source, so you can use and self-host it for free.

### What are the best alternatives to AdSense?

The closest alternatives to AdSense are AdMob, Admob MCP Server, Google AdSense, Google Analytics 4 MCP and Google Ads + Meta Ads + SEO/GEO MCP.

## Where this comes from

- Description: written from the project's README and its MCP Registry entry.

## Alternatives

- [AdMob](https://ai-powered.com/mcp/admob): AdMob is an open-source MCP server for analytics and data.
- [Admob MCP Server](https://ai-powered.com/mcp/admob-mcp-server): Admob MCP Server is an open-source MCP server for analytics and data.
- [Google AdSense](https://ai-powered.com/mcp/google-adsense): Google AdSense is an open-source MCP server for marketing and seo.
- [Google Analytics 4 MCP](https://ai-powered.com/mcp/google-analytics-4-mcp): Google Analytics 4 MCP is an open-source MCP server for analytics and data.
- [Google Ads + Meta Ads + SEO/GEO MCP](https://ai-powered.com/mcp/google-ads-meta-ads-seo-geo-mcp): Google Ads + Meta Ads + SEO/GEO MCP is a freemium MCP server for marketing and seo.
- [QueryAtlas](https://ai-powered.com/mcp/queryatlas): QueryAtlas is a freemium MCP server for analytics and data.
- [Search Console MCP](https://ai-powered.com/mcp/search-console-mcp): Search Console MCP is an open-source MCP server for web search and scraping.
- [GravityAds MCP](https://ai-powered.com/mcp/gravityads-mcp): GravityAds MCP is an MCP server for marketing and seo.

---
Source: https://ai-powered.com/mcp/adsense
