What are Query Parameters?

Query parameters are part of a URL that follow the question mark (?) and are used to define specific content or actions based on the data being passed.

In web analytics, they're often used to track the effectiveness of online marketing campaigns by distinguishing between traffic sources, such as different advertisements or email campaigns, enabling more precise analysis of user behavior and campaign performance.

Examples of query parameters

Query parameters consist of a key-value pair, separated by an equal sign (=), and multiple parameters can be joined using an ampersand (&).

These parameters can influence the content or functionality of the web page being loaded, making them versatile tools for tracking, filtering, personalizing content, and more.

Here are some common examples:

Tracking and analytics

  • utm_source: Identifies the source of traffic, e.g., 'utm_source=google'.
  • utm_medium: Specifies the medium used, such as email, cpc, or social.
  • utm_campaign: Names the specific marketing campaign e.g., 'utm_campaign=bogo'.

Put together, the full URL may look like this:


Content filtering and sorting

  • sort: Defines the order in which content is displayed, e.g., sort=price_asc for ascending price.
  • filter: Applies specific filters, like filter=category_shirts, to display only relevant items.

Search queries

  • q or query: Contains the user's search terms, e.g., q=womens+shorts.