Latest Intelligence From the Field

Call Tracking with Twilio & Google Analytics using Twimlbin

Nearly a year ago, I was working on a new feature for an app powered by Twilio when I realized that it would be significantly easier to get started with Twilio’s TwiML if hosting an XML file could be removed from the equation. Several weeks ago, Twimlbin was born. One of the features we needed to implement quickly was the ability to track calls both as a pageview and an event in Google Analytics. After building this feature, we found it more and more useful for many other call tracking instances. With this feature and the TwiML <Redirect> secondary verb, it’s possible to use Twimlbin as a basic analytics proxy – something we find incredibly useful.

How to setup Call Tracking

Simply create a new Twimlbin and set it to redirect to either a number directly or your script or you can clone one of the example bins we’ve provided.

For a Number: Clone this bin and replace the number with your own.


For a Script: Clone this bin and replace the URL with your app’s location.


Once you’ve setup the Twimlbin, simply put in your Google Analytics ID (near the bottom of the page) and you’re ready to go. You can even watch calls in realtime with the new Google Realtime Analytics feature.

twimlbin analytics calltracking

We hope you enjoy Twimlbin as much as we do. Tweet @TwimlBin if you have questions!