Enable product preview functionality in Headless frontend

Shopify Partner
2 0 3

We are currently building a headless frontend using nextjs and hydrogen-react. We added some redirect logic similar to the one in the recommended online shop theme to redirect some URLs to the custom frontend which works well. 


The only thing that does not work is the Preview button functionality found in the product edit screens in the shopify backend. Instead of a product's handle a preview_key parameter is passed to the template. Is there any way to fetch the actual product from this key?


What's the Shopify team's recommendation to use the product preview with a headless (e.g. hydrogen-based) frontend?



Replies 0 (0)