eCommerce: Margin Based Reporting Make More Profit

Conversion Rate Optimisation
Digital Marketing
Paid Media
Performance Marketing

eCommerce: Margin Based Reporting Make More Profit

The success of any eCommerce website relies heavily on the data we collect and how we use that data to improve performance. Google Analytics and other digital analytics solutions have given us the ability to easily collect sales data and tie this back to specific marketing activity or on-site behaviour. However, these tools generally don’t give us the complete picture.

The default approach to eCommerce measurement is revenue-based: the listed price of products and the quantity sold give us a total revenue figure, which is then used to optimise performance. But there is a better approach.

In the example below, we see that Product A sold the most in terms of quantity and was also a much bigger contributor to overall revenue. Using our default eCommerce data, we would optimise to sell more of these in order to drive higher revenue.

However, as soon as we introduce our margin data the picture changes drastically. While Product A sells more, there are also higher costs involved and as such has a much smaller profit margin. Even though Product B sold less, it had more of an impact on the bottom line and we should in fact be optimising marketing efforts to drive more of these sales.

A margin-based view to reporting and optimisation is a more accurate representation of what is driving the bottom line. But how do you go about integrating this with your existing data?

There are two approaches we can take to getting a view on product margin level performance: importing margin data into Google Analytics, or exporting Google Analytics data into a custom reporting solution.


The first is to bring margin data into Google Analytics. The ‘Data Import’ functionality provides a method of augmenting existing data via .csv file imports. 

In this case, using our product SKU as a key, we can upload product margin data directly into Google Analytics.

The process is relatively straightforward. In order to apply this information to historical data, we’ll make use of calculated metrics for-profit and margin specific fields. This means that our data import only needs to consist of the cost associated with each product – the rest we’ll calculate in Google Analytics.

Before we import any data, we first need to set up a custom metric that will house the uploaded product cost data:

Once done, we can configure our .csv file for upload. This needs to consist of a list of product SKUs with the associated cost of each product.

Next, we can configure our data upload schema to match this structure, as per the below, before uploading the dataset.

With our upload data in place, the last step is to create calculated metrics for our remaining profit and margin data points. These can be configured as follows:

The output of this can look similar to the examples below, where we are able to view product margins and profits segmented by the existing Google Analytics dimensions. 

This gives us a lot more flexibility when it comes to decision making, as we can now optimise performance based on what’s actually driving the bottom line.

If you are familiar with the Google Analytics interface this can be a quick and simple solution. This tends to be geared towards a more static product line that seldomly changes, though there is an API available to develop automated data imports.


An alternative approach is to connect Google Analytics data to live product margin information in an existing data warehouse or business intelligence tool. Getting data out of Google Analytics is just as easy as importing, with multiple solutions and tools that connect to the Google Analytics API.

This has the added benefit of allowing you to integrate with BI reporting solutions such as Power BI or Tableau.

With this approach we can get rid of unnecessary data and focus only on the information that gives us actionable insight.

Whichever method is used, the advantage that margin based reporting gives us is clear. With an accurate view of what’s driving the profit, we are able to optimise campaigns, promotions or user experience in order to maximise the impact on the bottom line, rather than on total revenue.

Author : Derik Nieman