Skip to product information
1 of 1
Published:2023.01.17

How to set OGP images using metafields on "Pages" in the Shopify theme "Dawn"

How to set OGP images using metafields on "Pages" in the Shopify theme "Dawn"

Applications

  • Social Media

How to implement

  • LIQUID
View full details

In Shopify, the OGP images displayed on the home page, product details, blogs, and other pages when shared on social media can be individually set by default, but this is not the case for "Pages," so the OGP image on the home page is displayed for all pages. Therefore, it would be convenient to be able to set these individually using meta fields.


Create a metafield


Edit snippets/meta-tags.liquid


Check with the test tool


After making a purchase (all items are ¥0), you will be able to view the sample code.

If you have already made a purchase, please login here.

Sample Codes

Test Theme :Dawn/Rise 15.2.0

Rewrite the meta field value to call it preferentially (if there is no meta field value, the normal OGP image is called)

Related Post