How to Add Google Analytics Event Tracking in WordPress

Would you like to track client movement or event tracking while they are using your website with WordPress theme? You can track site’s hits, referral source, time spent on page, and a great deal more by means of Google Analytics tool, yet for additional top to bottom bits of knowledge, you should use event tracking. In this article, we will demonstrate to you generally accepted methods to include Google Analytics event tracking on a website with WordPress template.

What is Event Tracking option in Google Analytics to add to a WooCommerce template?

Event tracking permits you to quantify client connections on your website with a WooCommerce template. These co-operations can be things like tapping on a catch, playing a video, downloading documents, submitting structures, and so forth.

You should assume you added a video to your item page, and now need to know how viable it is for your transformations. Event tracking permits you to track what number of clients played the video, so you can decide for yourself whether to add it or not to your website with a WooCommerce theme.

Another case is Ajax based structure entries. In the event that you are utilizing Gravity Forms or some other contact structure plugin, then frame accommodation does not come about into another website’s hit.

Utilizing event tracking you can perceive how clients cooperated with a structure. The same goes for record downloads included on a page. You can track what number of clients downloaded a document utilizing event tracking and even which catch on the page was clicked most.

Event tracking is not quite the same as tracking connections in Google investigation. You can track events on the site with WooCommerce themes utilizing Google Analytics by basically adding UTM source to a connection.

These quantifiable activities permit you to perceive how clients act on your site. You can then change your system to include content that create more client engagement and association. Eventually this implies more deals and transformations on your website.

Before beginning, you should setup and introduce Google Analytics on your WordPress site. In the event that you are not acquainted with utilizing Google Analytics, then you can attempt our tenderfoot’s aide on the best way to utilize Google Analytics.

In the event that you are as of now utilizing Google Analytics, then you can bounce directly into event tracking adding to your website with one of WooCommerce themes.

Use Universal Analytics Code on websites with WordPress themes

There are as of now two sort of Google Analytics executed on sites. Google is gradually asking so as to push out the more seasoned code website admin to utilize more current “Universal Analytics Code”.

On the off chance that your Google Analytics code resembles this code:

<script>

(function(i,s,o,g,r,a,m){i[‘GoogleAnalyticsObject’]=r;i[r]=i[r]||function(){

(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),

m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)

})(window,document,’script’,’//www.google-analytics.com/analytics.js’,’ga’);

ga(‘create’, ‘UA-XXXXXX-1’, ‘auto’);

ga(‘send’, ‘site visit’);

</script>

At that point you are now utilizing the more current Universal Analytics code on the website with one of WordPress themes. There is no activity required, and you can proceed onward to the following step.

On the off chance that your code does not resemble this, then you are presumably utilizing the more established Google Analytics code. You should redesign, Google has an itemized update guide for that. Fundamentally on the off chance that you are not utilizing propelled tracking elements as a part of Google Analytics, then you can simply switch the old code with the new one from your account’s property settings.

Making an event in Google Analytics tool

  • Essentially sign into your Analytics dashboard and snap on the Admin join at the top;
  • On the off chance that you have various sites under your investigation account;
  • Then ensure that you are survey the dashboard for the site where you need to include the event;
  • There are three sections under the administrator page. Click on the “Objectives” join under the “Perspective” segment;
  • Snap on the new objective catch to make an objective. From the Goal Setup alternatives, you have to choose the custom choice and afterward tap on the following catch to proceed;
  • This will convey you to the Goal Description step. You have to give a title to your custom objective; this is something that will offer you some assistance with identifying the objective inside Google Analytics included into your WordPress theme;
  • Under the objective sort, you have to choose Event. Then tap on the following step catch to proceed;
  • The last step is to give objective points of interest. You should enter the event conditions here;
  • Examination will check a transformation when every one of these conditions matches.

Including Google Analytics Event Tracking with onClick

The most straightforward and maybe the quickest approach to include Google Analytics event using so as to track is the onclick system. This strategy essentially sends event conditions to Google Analytics when client taps on a component. You must add the onClick parameter to the download connection utilizing this organization. For this purpose use such code:

onClick=”ga(‘send’, ‘event’, ‘classification’, ‘activity’, ‘mark’, ‘value’);”

You should supplant classification, activity, name, and esteem with your event’s conditions. At last your download connection would resemble this. Use such code:

<a onClick=”ga(‘send’, ‘event’, ‘Downloads’, ‘Click’, ‘Digital book downloaded’, ‘0’);” href=”http://example.com/wp-substance/transfers/2015/06/free-ebook.pdf”>Download Free Ebook</a>

That is all, when clients click on this connection; it will send an event to Google Analytics which will show up in your website with a WordPress theme or a WooCommerce template.

In a case you have any questions about adding Event Tracking for Google Analytics to a website with WooCommerce template or WordPress theme; you can ask them on our forum or via the Technical Support.

How to Send Email in WordPress using the Gmail SMTP Server
How to Add Attachment File Type Icons in WordPress

Leave a Reply

Your email address will not be published. Required fields are marked *

Navigation

Close

Categories