Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Combining Content Data in Google Analytics

When I first start one of my Wordpress blogs, I had the permanent URL for each post include the date of posting.

The slug format looked like this: /blog/2010/01/25/this-is-my-article/

Later on, I changed it so that the date was not included in the permanent URL, like this: /blog/this-is-my-article/ and setup a redirect plugin to make sure that users would get to the page they wanted until the site was re-indexed.

In Google Analytics, when I review the stats for content I now have multiple records for what is essentially the same page. ie:

Top Content List:

  1. 45 Pageviews- /blog/this-is-my-article/
  2. 24 Pageviews- /blog/2010/01/25/this-is-my-article/
  3. 33 Pageviews- /blog/some-other-article/

Is there any way to combine those records somehow?

like image 872
David Csonka Avatar asked Mar 19 '10 17:03

David Csonka


People also ask

Can you merge two Google Analytics properties?

In short - yes. Google Data Studio allows you to add multiple data sources to a single report including 2 or more Google Analytics Properties. You also have the option of blending data from two sources into a single chart/table if they have at least one common dimension that you can use as a join key.

Is content grouping retroactive in Google Analytics?

The crux of the problem is that most changes in Google Analytics do not take effect retroactively. If we were to enable a content grouping, for example, or implement a new custom dimension, we won't magically get access to historic data.


1 Answers

I think the most straightforward way to do this is by using Filters, "Advanced Filters" in particular. In your case, you'll use one Filter for each blog-article pair (one URL w/ title + date, the other URL w/ title only)--this way, you'll merge the two URLs into a single line item in your reports.

(I'm assuming you haven't done this before, so,

  1. from the "Settings" Page in GA, click on "Filter Manager" (probably bottom right)

  2. Click "Add Filter"

  3. Enter a name for this Filter (article name is probably a good choice)

  4. Click the radio-button below that textbox, "Custom Filter"

  5. Then Click the last of a set of six radio buttons below that, "Advanced"

  6. for "Field -> A -> Extract A" select "Request URI" from the dropdown menu

  7. Beside that menu is a textbox, type in the article title (this-is-my-article)--no parens, no quotes

  8. The next line ("Field B -> ....") leave blank

  9. The line after that, which begins with "Output To->" select "Request URI" from the dropdown

  10. Type in the article title (with "/" at the beginning, no space; and ".html" at the end, no space)

  11. Click "Yes" for "Field A Required"

  12. Click "No" for "Field B Required"

  13. Click "Yes" for Override Output Field

  14. Click "No" for "Case Sensitive"

  15. Below that, you'll select which of your Website Profiles you want to apply this Filter to

  16. Click "save changes" and you're done (obviously you'll need to repeat this process for each URL pair).

like image 81
doug Avatar answered Oct 12 '22 11:10

doug