Every online business, have worked hard and spent hours agonizing over decisions about how their website should look, feel, and be constructed. Each of these decisions will generate future costs and opportunities, shaping how the business operates. One such decision that you will have to take is deciding the URL structure. Well, you may think that its simple and maybe you have logically created all the data but have you structured the URLs with data gathering in mind?
Measuring performance over time is important and with data gathering URL structures it’s easy and hassle-free.
Usually, people create URL’s keeping in mind that the products need to sit at the root. For example xyz.com/first-product-name
Apparently a lot of websites whose product pages rank have this type of URL.
At one level it makes sense: a product might be in multiple categories so you would want to avoid duplicate content. Moreover, if you would want to change the categories, you wouldn’t want to have to redirect all the products.
Is it feasible from a data-gathering point of view?
There is now no way in Google Analytics to select all the products. There is no way through which you can separate the product URLs from other URLs we might have at the root.
So, while measuring performance, one has to either collect a list of all the data URLs or one might have to crawl all the pages and then pick out the product pages with an HTML footprint. Once they’ve got the entire product URLs, they’ll then have to match this data to Google Analytics.
Now, this is a lengthy process. And if you want to do this analysis regularly, the list will constantly change. The range of products will change. So it is necessary to have an automated report.
Now, if we have all the products in a folder called /products/, this entire lengthy process becomes one step.
Load the landing pages report in Google Analytics and filter for URLs beginning with /product/
What is unique about a URL?
URL is the main piece of information you can use to identify the page. Google Analytics, Google Search Console, log files, all of these have access to the URL. You may also require working with templates and generalizing across groups of similar pages, which can be done through URLs.
How should you set up your URLs?
A good URL pattern is ideally using contains rather than any complicated regex. This usually means we’re talking about adding folders because they’re easiest to find with just a filter.
We also want to keep things human-readable when possible, so we need to bear that in mind when choosing our folders.
For example: Let’s suppose we’re setting up product URLs for a fashion e-commerce store. We should put the URLs in a /product/ folder. The most plausible grouping for products is the product category.
Now, while creating a URL for a black midi dress, we will have to create “dress” as a category. It is far more suitable if we split all our products into:
These are unlikely to change and, having this type of hierarchy at the top makes a lot of sense. You can always consult an SEO services company while structuring your URL.