Amami MCP docs

Migrate from Google Analytics and GA4 to privacy-minded analytics

Migration has two parts: replacing tracking going forward and preserving access to historical data. Amami focuses on clean future collection and AI analysis. Historical imports depend on the source system and your deployment.

This guide is for teams evaluating a Google Analytics alternative that need a controlled cutover rather than a blind script swap. Start with Tracking and events if your event inventory is not documented yet.

General migration steps

  • Create an Amami website.
  • Add the Amami tracking script.
  • Map important events.
  • Keep the old analytics tool available for historical reference during the transition.
  • Verify realtime pageviews and events.
  • Run an AI instrumentation review.
  • Remove the old script after validation.

Before you start

  • List the reports, dashboards, exports, and stakeholders that depend on your current analytics setup.
  • Record the pages and events that must be present after cutover.
  • Keep the existing analytics tool available while you validate new collection and historical access.
  • Decide whether the new deployment needs a self-hosted endpoint, a specific retention policy, or a legal review for your organization.

From Google Analytics

Replace GA4 scripts with Amami tracking:

<script defer src="https://dashboard.amami.dev/script.js" data-website-id="WEBSITE_ID"></script>

Map common events:

  • sign_up becomes signup_completed.
  • purchase becomes purchase_completed.
  • page_view is usually automatic.
  • click events should become named actions such as pricing_cta_click.

Keep GA4 access for historical reports, especially if stakeholders depend on older dashboards.

From Plausible

Replace the Plausible script with the Amami script. Map custom goals to Amami events:

umami.track('Signup');
umami.track('Purchase', { plan: 'Pro' });

Use UTM parameters consistently after migration so the assistant can compare campaigns cleanly.

From Fathom

Replace Fathom's script with Amami's tracking script. Convert goal IDs into readable event names:

  • GOAL_ID_A becomes signup_completed.
  • GOAL_ID_B becomes checkout_completed.
  • Manual pageview calls are usually unnecessary unless your SPA needs route handling.

From another privacy-first analytics instance

For a self-hosted migration, plan:

  • Database backup.
  • Version compatibility.
  • Environment variable review.
  • Domain and script URL changes.
  • API key rotation.
  • Tracking script verification.

For Cloud migration, create new websites in Amami and start clean collection unless your team has a validated import path.

Validate and roll back safely

After adding the new script, compare a small set of representative pageviews and important events before removing the old script. Check the browser network request, realtime reporting, and a known conversion path.

If a required event or pageview is missing, keep the existing script in place, correct the new tracking configuration, and repeat the validation. Do not remove the old script until your acceptance checklist passes.

Read Installation for the tracking script, Tracking events for event naming, and MCP config before connecting an AI assistant.

Ask AI to validate migration

Review this project for old analytics scripts. Identify GA4, Plausible, Fathom, Matomo, or old analytics snippets, then tell me how to replace them with Amami tracking.
After migration, verify Amami pageviews and events. Tell me which old goals still need equivalent Amami events.