All things Shopify and commerce
We're moving the community! Starting July 7, the current community will be read-only for approx. 2 weeks. You can browse content, but posting will be temporarily unavailable. Learn more
Good day all!
How can I access to edit/add meta description for Shopify Collections (all) page? I searched all over the place and yes, I can access the template, but how do I edit the meta description and title?
Collections – Nectar Flowers Ottawa
https://nectarflowersottawa.ca/collections/
Thank you so much!
Hi @Carpinus ,
This will require updating theme.liquid file. Can you provide me a copy of theme.liquid ?? And also let me know that the new meta title/description?
I was able to add custom meta title/description on the mentioned page https://mangit.myshopify.com/collections/ by editing the template file.
Thank you so much!!!
Could you please share the code for the template file - would love to try it!
Did you managed to fix that issue?
Hi @magdalena @Carpinus ,
This depends on the theme. However you can fllow below steps to get this done. In the theme.liquid file there should be code for meta title and description.
Please replace
<title>
{{ page_title }}
{%- if current_tags %} – tagged "{{ current_tags | join: ', ' }}"{% endif -%}
{%- if current_page != 1 %} – Page {{ current_page }}{% endif -%}
{%- unless page_title contains shop.name %} – {{ shop.name }}{% endunless -%}
</title>
{% if page_description %}
<meta name="description" content="{{ page_description | escape }}">
{% endif %}
With
{% if request.page_type == 'list-collections' %}
<title>New Title Here</title>
<meta name="description" content="New Description Here">
{% else %}
<title>
{{ page_title }}
{%- if current_tags %} – tagged "{{ current_tags | join: ', ' }}"{% endif -%}
{%- if current_page != 1 %} – Page {{ current_page }}{% endif -%}
{%- unless page_title contains shop.name %} – {{ shop.name }}{% endunless -%}
</title>
{% if page_description %}
<meta name="description" content="{{ page_description | escape }}">
{% endif %}
{% endif %}