# Fathom Analytics MCP

> Fathom Analytics connects your website data to any AI agent for privacy-first analytics. Instead of navigating complex dashboards or running manual queries, you ask natural language questions about site traffic, visitor counts, and conversion events directly in the chat. Get real-time metrics, run historical reports, and manage entire sites from one place.

## Overview
- **Category:** data-analytics
- **Price:** Free
- **Tags:** analytics, privacy-first, website-tracking, event-tracking, visitor-stats

## Description

Connecting your Fathom Analytics account lets you monitor website performance without sacrificing user privacy. You treat your analytics like a conversation. Need to know how many visitors logged on this morning? Just ask. Want to see unique pageviews compared to last month's bounce rates? Your agent handles the complex data aggregation for you. This means you stop jumping between tabs and start getting answers instantly. You can manage your entire site structure—listing, creating, or deleting sites and tracking specific business goals with milestones—all through natural conversation. It’s like having a dedicated data analyst sitting right next to you, powered by Vinkius, who knows every corner of your Fathom account. The goal is simple: get the insights you need without ever opening a separate dashboard.

## Tools

### get_account
Retrieves core administrative details about the owner of this Fathom API token.

### get_aggregations
Generates detailed, flexible reports by grouping and filtering data metrics across specific timeframes.

### create_event
Adds a brand-new custom conversion tracking event to a specific site.

### create_milestone
Sets up a new significant business milestone for the site.

### create_site
Registers and initializes an entirely new Fathom analytics website.

### get_current_visitors
Returns the immediate total count of people actively viewing a page on your site right now.

### delete_event
Removes a specific, existing conversion event from the site’s tracking list.

### delete_milestone
Permanently removes an established business milestone for the site.

### delete_site
Completely and permanently deletes a Fathom site from your account.

### get_event
Fetches all details for a specific conversion event using its unique ID.

### get_milestone
Retrieves the full definition and status of a single milestone by its ID.

### get_site
Fetches all configuration details for one specific Fathom site using its ID.

### list_events
Provides a complete list of every conversion event currently tracked for the site.

### list_milestones
Lists all defined milestones, allowing you to see what tracking goals are active on the site.

### list_sites
Retrieves a paginated list of every Fathom website associated with your API key.

### update_event
Changes the details or settings for an existing conversion event.

### update_milestone
Modifies the parameters or description of a milestone you already defined.

### update_site
Updates general settings and configurations for an existing Fathom site.

### wipe_event
Clears all accumulated completion data associated with a specific event type.

### wipe_site
Resets the entire site by wiping all recorded pageviews and conversion completions.

## Prompt Examples

**Prompt:** 
```
How many visitors are currently on my site with ID CNDY123?
```

**Response:** 
```
Checking real-time data... There are currently 42 active visitors on your site (ID: CNDY123).
```

**Prompt:** 
```
List all the sites in my Fathom account.
```

**Response:** 
```
I've retrieved your sites. You have 3 sites: 'Personal Blog' (ID: BLOG1), 'E-commerce Store' (ID: SHOP2), and 'Portfolio' (ID: PORT3).
```

**Prompt:** 
```
Get the pageviews and unique visitors for site SHOP2 for the last 7 days.
```

**Response:** 
```
Fetching aggregations... For the last 7 days, site SHOP2 had 1,250 pageviews and 890 unique visitors.
```

## Capabilities

### Check live site traffic
Retrieves the total number of visitors currently active on a specific website.

### Generate custom data reports
Creates flexible historical reports by grouping and filtering metrics like pageviews or unique users over time periods.

### List and manage sites
Allows you to view, create, update, or delete entire Fathom websites within the system.

### Track events and goals
Monitors specific user conversions (events) and tracks major business achievements (milestones).

### View account details
Quickly fetches information about the owner of the Fathom API account.

## Use Cases

### A campaign just launched and I need immediate performance checks.
Instead of waiting for the end-of-day report, the agent instantly runs `get_aggregations` for the last 24 hours. The user asks: 'What were the pageviews and unique visitors for site SHOP2 over the past week?' The agent returns the numbers in a clean chat format.

### I need to add new tracking goals because our product changed.
The developer uses `create_milestone` to set up 'Free Trial Signups' and then calls `list_events` afterward. This confirms that the event ID is registered correctly before they integrate it into their application code.

### We are sunsetting an old product line and need to clean up tracking.
The marketing team first runs `list_sites` to confirm all necessary sites, then uses `delete_event` for the old 'Product X View' event. Finally, they call `wipe_site` on that site just to be sure the historical data is zeroed out.

### A new developer needs to replicate a live test environment.
The engineer uses `create_site` to spin up a dedicated staging site ID. They then use `get_account` to verify that the API token has permission to manage this newly created, isolated testing environment.

## Benefits

- Stop switching between tabs. Instead of jumping to the Fathom dashboard to check current traffic, you simply ask your agent for live data using `get_current_visitors` and get an instant answer.
- Run complex reports without writing SQL or building custom views. You can request historical comparisons—like pageviews vs. unique visitors over 7 days—using `get_aggregations` in a simple text prompt.
- Manage your entire site taxonomy from the chat window. Need to add a new goal? Use `create_milestone`. Want to decommission an old event? Call `delete_event` and you're done, no UI clicks needed.
- Maintain data integrity by using dedicated tools like `list_sites` before you try to update any site details with `update_site`, ensuring you always have the correct IDs.
- It respects your privacy. You get powerful analytics access without having to deal with complex API calls or worrying about compliance, because it's built around Fathom’s private data model.

## How It Works

The bottom line is that you get data answers immediately without ever leaving your current chat or development environment.

1. Subscribe to this MCP and provide your Fathom API token.
2. Your AI client receives access to all site, event, and aggregation tools.
3. You ask natural questions like, 'What were the pageviews for Site X last week?' and receive a direct answer.

## Frequently Asked Questions

**How do I check current visitors using get_current_visitors?**
You simply ask your agent for the live count. You don't need to worry about timeframes or historical data; it gives you the total active visitor number right now.

**What is the difference between list_events and get_event?**
Use `list_events` if you want to see every type of conversion goal currently tracked on your site. Use `get_event` when you already know the exact ID for a specific event and just need its details.

**Can I use get_aggregations to compare different metrics?**
Yes, that's what it's designed for. You can request reports that group and filter data across multiple dimensions—like comparing pageviews against bounce rates over a specific date range.

**If I want to delete a site, should I use delete_site or wipe_site?**
They do different things. `delete_site` removes the whole site from your account. `wipe_site` keeps the site but zeros out all recorded traffic and event completions.

**How do I list all sites in my Fathom account?**
You use the `list_sites` tool. This will return a paginated list of every single website associated with your API key, letting you see what's active.

**How do I set up tracking for a completely new goal using `create_event` or `create_milestone`?**
You initiate a new asset by calling the appropriate creation tool. You must provide the site ID and necessary parameters, such as the event title or milestone description. This process creates the unique tracking definition within your Fathom account.

**If I need to rename or adjust the properties of an existing goal, how do I use `update_event`?**
You call `update_event` using the specific event ID. This modifies the metadata—like changing the title or description—without disrupting any historical data associated with that event.

**Is there a difference between calling `wipe_event` and using `delete_event` on an old tracking goal?**
Yes, they do different things. `wipe_event` only removes the completion data, leaving the event definition intact for future use. However, `delete_event` permanently removes the entire event from your account.

**Can I see how many people are on my website right now?**
Yes! Use the `getCurrentVisitors` tool with your Site ID to get the current number of active visitors on your website in real-time.

**How do I get a summary of my traffic for a specific period?**
You can use the `get_aggregations` tool. It allows you to specify metrics like `pageviews` or `uniques` and define time filters to get summarized data.

**Can I manage my site settings through this integration?**
Absolutely. You can use `list_sites` to see all your sites, `create_site` to add new ones, and `update_site` to change names or sharing preferences.