There are two methods to achieve tracking PDF downloads on your website using Google Analytics. The first requires access to your website and amending the LINKS. The second and best method is to set up Event Tracking in Google Analytics Dashboard so the PDF is tracked as a page view.

  1. Amending the Link To A PDF

Access the web page with the download link for your PDF file and amend the A HREF command to include the ONCLICK instruction below highlighted in RED. Note it is always good practice to open a PDF in a New Window, this what the target=”_blank” command does.

  1. Configuring Tracking As A Page View

First you need to sign up for GOOGLE TAG MANAGER at

You will receive a GOOGLE TAG MANAGER CODE to install in the BODY of the web page.

Now select TRIGGERS from the left hand menu and click NEW to create the TRIGGER


Select CLICK

Now configure the CLICK for JUST TAGS with a MAX WAIT of 2000 milliseconds and CONTINUE


We now configure the TRIGGER just for PDF downloads

Select PAGE URL > select matches REGEx (Ignorecase) > add \.pdf

Then Continue


We now need to Fire this on ALL CLICKS


Create the Trigger & Save It


Now we need to create the TAG to record this as a Virtual Pageview

Select TAGS from the left hand menu and NEW

Now select GOOGLE ANALYTICS and select it to UNIVERSAL and continue


Now we configure the TAG

Enter your Google Tracking ID and select PAGE VIEWS and click on MORE SETTINGS, then select Fields to Set



Enter Field Name as page and the value as {{click URL}} then continue.


Now ensure you set the FIRE ON to CLICK and in the pop up box Tick PDFs and Save


You now have set the TAG click on Create TAG


Label it and SAVE


Like this Article ? Please Share

Other Web Design Articles You May Like

Touch Base With Us

Let’s Talk About How Web Design Can Get You Noticed
Betelguise Web Design

Lasyard House, Underhill Street
Bridgnorth, Shropshire, WV16 4BB

Telephone : 01746 250500
Email :

[contact-form-7 id=”19″ title=”Contact form” /]