Page URL is a dimension available in only some areas of Adobe Analytics, such as Data Warehouse. It is not available by default in Reports & Analytics or Ad Hoc Analysis. If users want to use this dimension in reporting, Adobe recommends capturing page URL in an eVar. An eVar allows the user to credit URL to events while using a higher byte limit of 255 (versus a prop's byte limit of 100). There are several ways to populate page URL across your report suite:
- Use processing rules: Processing rules allow a user to conditionally assign variable values. Create a rule set to trigger 'always', overwriting eVarX with Page URL. See more on Processing Rules.
- Using dynamic variables within your implementation: Setting eVarX="D=g" automatically places the page URL when arriving at Adobe data collection servers. This method supports both legacy and DTM implementations. See more on dynamic variables.
- Blank out s.pageName: If the pageName variable is not defined, it defaults to collecting the URL. This method is not optimal for customers already capturing page name values.
Many customers find that the full URL provides too much separation. HTTP and HTTPS versions of the same page are separated. URLs with differing query strings or anchor tags are also separated. If you would like to combine these values, Adobe recommends populating a custom variable using selective parts of the URL that are valuable to you.
If you are using a legacy implementation, assign an eVar to the following value:
s.eVar1= [location.host, location.pathname].join('');
If you are using a DTM implementation, create a custom script data element and place the following in the code editor:
var url = [location.host, location.pathname].join(''); return url;
If you want to collect this selective URL in multiple variables, use dynamic variables that point to your custom URL variable.