Scroll to top

Best Way to Configure Magento & Google Analytics Reporting

No comments

A large number of Magento store owners do not utilize all the fantastic eCommerce features that are built-in with Google Analytics. These features include eCommerce tracking, conversion, and goal-related tracking, demographics, visitor segmentation, and funnel visualization. All of them can help any business truly understand its market.

Ensuring that Google Analytics is set up correctly at your website can be daunting at first glance due to the complex functionality it maintains. Since the brought change to Universal code, there is not much information written about it. Installing Google Analytics may be frustrating, particularly when you face a problem of your website not tracking the way it used to or the way you planned it to. The three most common challenges for installation are also the three most critical components for any Magento eCommerce business: tracking demographics, eCommerce statistics, and conversions.

Below are five tips that will help you overcome these challenges and ensure that your Google Analytics functionality performs as good as it can.

Applying the Universal Google Analytics Tracking Code

Make sure you have the new Universal Google Analytics tracking code implemented at your Magento website. Go to your Google Analytics ACCOUNT and PROPERTY columns, select the property you’re working with. Click Tracking Info > Tracking Code. Follow the directions and copy and paste this into your source code website. This task can be completed in a number of ways. For example, you should copy and paste the code into your child theme under the /template/page/html/head.phtml file in Magento which is on every page of the website. Paste it immediately before the closing tag. The code must be on every page of the website so the data can be appropriately tracked.

View the source code of the Magento website to confirm the code has been added correctly. You can do this using the Developer Tools in your browser. You can use the Real-Time tracking in Google Analytics to confirm the information is being tracked./
If you need help with your Magento store, Contact us here.

Configuring Your Magento Google Analytics API

Make sure your Google API is enabled and configured in your Magento admin.
You can find it under Configure > Sales > Google API.

Enabling Google Analytics Demographics

Once you have the standard Universal Google Analytics tracking code implemented, you will not automatically see demographics load. To enable this, you need to include the proper code and then verify it under the Audience > Demographics > Overview > tab.

Property settings demographics enabled

Below are two important Google articles that describe this process. You need to use the universal code and include the bold part below in the tracking code:

To enable Display Advertising (Demographics) features for Universal Analytics, insert the bold line into your existing tracking code between the ‘create’ and ‘send’ commands, as seen in this example:

// ga(‘require’, ‘displayfeatures’); ga(‘send’, ‘pageview’); // ]]><-/script->

If you still do not see this data loading, make sure you check the Property settings in your Google Analytics account. Make sure demographics are enabled.

Google Demographics overview

Once this is completed, then you verify the code, and the demographics should load.

Google Analytics eCommerce Tracking

General eCommerce tracking helps you see your marketing campaigns, coupons, affiliations, average sales, revenue, and general conversions. This can go found under your Google Analytics > Conversions > Ecommerce > Overview > tab to see if Ecommerce is being tracked.

Ecommerce tracking screen

If you do not see this loading, you can troubleshoot the issue through the following steps:

  • Go to your Admin > eCommerce Settings and confirm the eCommerce tracking has been enabled.
  • If this is not enabled, it won’t probably load the data. Also, remember to double-check the steps above to track the data successfully.

Ecommerce settings

Google Analytics Conversion Tracking Utilizing Goals

Conversion tracking can vary based on your needs and particular goals. This is just one example to get you started with Goals and Conversion tracking.

Google Analytics Conversion Tracking

1. Check the tracking code is correct and implemented properly

  • To get the tracking code, log onto Google Analytics.
  • From the ACCOUNT and PROPERTY columns, select the property you’re working with. Click Tracking Info > Tracking Code.

2. Conversions will not be tracked if the proper code is not added to the success page once someone places an order.

  • Generally, adding the tracking code to the Magento HTML Head through Magento’s configuration (Configuration > Web > HTML Head) should be enough. If, for whatever reason, it doesn’t seem to be tracking on the success page (sometimes a theme or extension will overwrite parts of Magento’s default functionality), then you might have to add the code manually.
  • To do this, using your FTP client, navigate to /app/design/frontend/template/checkout/success.phtml
  • Open that file in an editor and add the Google Analytics tracking code to the very bottom of the file. Save it, and reupload it.

3. Confirm your goals are appropriately configured. Note if the URLs are correct. If the URLs do not match, conversions will not work.

  • A good way to test this is to go under Real-Time > Conversions and then go through the process of checking out.
  • You should see your goals loading properly and the active users updating through each goal.
  • If you do not see a particular Goal showing up, then it is not configured properly. Go back to your Goals and check them. Purchase Made, Checkout Start & Confirmation
  • Goals – Go to Admin > Goals.
  • Check you have the proper URLs that match your website and Verify the Goal.
  • Make sure the Destination is set to the final success page and start the goal on the Shipping part of the checkout.

4. Once everything looks good. Go through the checkout process or wait for an order to confirm the Conversions are being tracked!

Related posts

Post a Comment