adCost Bug in Google Analytics API

Recently I’ve been using the Google Analytics API to automate some of the report generation I’m doing.

After some serious hair pulling I finally realized that there is a bug in the API when one of the metrics you request is adCost.

Specifically, when requesting adCost with other specific metrics, the results for adCost are always zero.

After some research I found this post which confirms that Google is aware of the adCost issue.

Unfortunately┬áthe post doesn’t really help much in terms of finding out which combinations trigger the bug, so I tried out some of the combinations myself found that using any traffic source dimension with these metrics will trigger the bug:

  • entrances
  • exits
  • exit %

If you are aware of other metrics that trigger this bug, please let me know and I’ll add them to the list.

I should add that this bug also affects custom reports!

If you’re using any traffic source dimension and adCost together with any of the above metrics in a custom report you’ll get zero for the adCost data.

Hopefully this saves someone else from some major hair pulling.

3 thoughts on “adCost Bug in Google Analytics API

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s