How do I alter the " - " separator prepended to shop.name in page titles

How do I alter the " - " hyphen separator prepended to shop.name used in page titles, to the more compact " | " pipe character. Where is it defined in my code tree. See example Shopify demo theme:

Hey @tojshp could you please tell me for which purpose you want to show pipe character for your theme or Shopify store.

If both then please follow this.

Usually in our shopify the page title look like this. Go to theme.liquid file and press ctrl + f and search for <title you will see tile taga and it look like this.


You can see there is hyphen separater. In order to change hyphen to Pipe character then please replace the exisitng code with this one.


If this was helpful mark as solution and like this post.

Thanks

1 Like

Thanks. For some reason I thought it was being set deeper than just in theme.liquid. In my theme it was using an – but it’s easily switched.

{%- unless page_title contains shop.name %} – {{ shop.name }}{% endunless -%}
{%- unless page_title contains shop.name %} | {{ shop.name }}{% endunless -%}

Thanks again.