Documentation

shop.url – Displays the home URL

shop.url — Displays your site’s home URL#

Description#

Use {{ shop.url }} to display your site’s home URL. This is the homepage address, not necessarily the WooCommerce Shop page.

Usage#

Place {{ shop.url }} in a field that supports placeholders, such as an email message.

To create a clickable link in an HTML email, place the placeholder in the link’s href attribute:

<a href="{{ shop.url }}">Visit our homepage</a>

You can also append a page path to the URL, provided you use the placeholder without UTM parameters:

<a href="{{ shop.url }}/thanks-for-buying/">Thank you for your purchase</a>

Replace /thanks-for-buying/ with an existing page path. Check the generated address to avoid duplicate slashes.

Parameters#

This placeholder supports five optional UTM parameters for campaign tracking:

  • utm_source — The traffic source, such as newsletter.
  • utm_medium — The marketing channel, such as email.
  • utm_campaign — The campaign name.
  • utm_content — A value distinguishing individual links or content variations.
  • utm_term — A keyword or another campaign detail.

For example:

{{ shop.url | utm_source: 'newsletter' | utm_medium: 'email' | utm_campaign: 'welcome' }}

Leave the UTM fields empty if you do not need campaign tracking.

Important: Do not append a page path after a placeholder containing UTM parameters. The parameters are added as a query string, so appending a path afterward can produce an incorrect destination. For a tracked link to a specific page, use that page’s complete URL and add its UTM parameters after the path.

Fallback#

This placeholder does not require customer, order, or product data. It reads the home URL from your WordPress configuration and can be used with any ShopMagic event.

Not the solution you are looking for?

Please check other articles or open a support ticket.