In this post I’ll continue from the post about How to Shorten a Bitly URL via Google Sheets, but exploring the data measurement part. First, we learned how to create a shortened link and now we’ll understand the process of how to know how many clicks that link has.
If you already have the requirements from the mentioned article, you don’t need to worry, as they remain the same and you can use the same spreadsheet you made for your own shortener. If you didn’t see the first one, the requirement was to have an active Bitly account and generate an access token.
Getting Clicks from the Shortened Link
I followed the same base from the previous article’s spreadsheet and only added a column with the call to get data from the shortened link. And to make this connection with the Bitly API I used the following formula:
In a simplified way, this formula validates to see if the shortened link (in cell F9) is actually a URL. If true, it will make a request to a URL where I request click metrics. If false, it returns an empty value. Once done, it will return the value with the number of clicks on that URL:
If you want to make a copy of the spreadsheet, the model used as a study base in this article is available here.
Besides clicks, other metrics that are possible to extract regarding clicks:
- Country
- Referring domains.
- Get the unshortened link.
For more details just access the Bitly documentation, where you’ll find this and other examples.
Boosting your Metrics
You can boost the data from these links by extracting Google Analytics data. One way to do this is using the tool’s own extension for Google Sheets or using a plugin like Supermetrics. If you shortened a parameterized URL, you’ll be able to filter your campaign’s data sources in these tools using the values inserted in your parameterization.
If you have any questions, don’t hesitate to comment!