Deploying Google Analytics With Django

后端 未结 10 1199
遇见更好的自我
遇见更好的自我 2020-12-23 11:29

We\'re about to deploy a new Django website, and we want to use Google Analytics to keep track of traffic on the site. However, we don\'t want all of the hits on developmen

10条回答
  •  滥情空心
    2020-12-23 12:26

    All of these other solutions may work, but they are all overkill now because you can easily set up a filter in Google Analytics to filter out all traffic that is not coming from your production website or websites. See Create/Manage Profile Filters in the GA Help. A solution with no code just makes everybody's life easier.

    Note: there are two caveats

    1. this doesn't work with realtime filtering, because no filters are applied to realtime (as of July 2012--check their documents)
    2. you have to be an admin with the Google Analytics account to set this up

提交回复
热议问题