Ben Borgers

How to disable Fathom Analytics in development environment

December 29, 2022

I’ve been using Fathom Analytics for years and I absolutely love it. If you want to sign up, I have a referral link that will give you $10 off!

Often you want to block yourself from being counted in your own page views while you develop your site.

One way to do this is to paste fathom.blockTrackingForMe() in your JavaScript console. However, you’ll have to remember to do this for each browser you develop in, and the setting will be removed if you clear your local storage.

Instead, you can use the data-included-domains setting that the Fathom tracking script provides.

If your website is under and, you can modify your Fathom script to look like this:


Note that you have to add both the “root” domain and the www subdomain if your site uses both.

Now, the script will only track page views on your production domains, and not in your local development environment.

Subscribe to my newsletter!

A weekly round-up of new blog posts and updates to projects I’m working on.