Search results for "{{ search.query }}"

No results found for "{{search.query}}". 
View All Results

Page Targeting Explained

Our page targeting options allow you to activate specific Hotjar features on specific pages of your site. To do this, you can either use one of our 6 page URL targeting options or use a JavaScript trigger (available on PLUS and BUSINESS plans).

URL Targeting

To better understand how URL targeting works, it is good to also understand what components form a URL:

What components form a URL

What components form a URL

Each URL match you enter can be one of five types:

  • Simple Match: This is the default match type and is used to target a page on your site - ignoring any query strings and fragments as well as protocol (http vs https) and the presence or not of 'www'.
  • Exact Match: Targets a specific URL, including the protocol, which can include a query string and fragment.
  • Starts With: Target all pages that have a URL, including the protocol, which starts with the entered text;
  • Ends With: Target all pages that have a URL which ends in the entered text;
  • Contains: Target all pages which contain the entered text;
  • Regular Expression: A regular expression (regex or regexp for short) is a special text string for describing a search pattern.

Let's explore in more detail the different options and how they would work.

Simple Match:

This is the default match type and is intended to be used to target a page on your site. The match will be correct if the URL path your visitor is on, matches the URL path you specify.

Note:

query strings and fragments are ignored if entered in the field

Example:
Simple Match - http://www.x.com/pages/

Exact Match:

The match will be correct if the URL path, querystring and fragment your visitor is on match EXACTLY the ones you specify.

Example:
Exact Match - http://www.x.com/pages/?x=1

Starts With:

The match will be correct if the URL your visitor is on, starts exactly as you specify it, including the protocol.

Example:
Starts with - http://www.x.com/pages/

Ends With:

The match will be correct if the URL your visitor is on, ends exactly as you specify it.

Example:
Ends with - pages/

Contains:

The match will be correct if the URL your visitor is on, contains the text you specified.

Example:
Contains - ?x=1

Regular Expressions:

For a detailed explanation of Regular Expressions and usage examples please read our knowledge base article: Using Regular Expressions

JavaScript Triggers

JavaScript triggers is a feature available for users on PLUS and BUSINESS plans. Triggers allow you to activate specific Hotjar features using a very simple snippet of code. For more details and examples, please visit our Using JavaScript Triggers article.

Page Targeting Explained