Hi everyone,
I’m working on a custom (headless) storefront built with TypeScript, using Shopify Storefront GraphQL API for cart and checkout.
Currently, my flow is:
-
Create a cart using the Storefront API
-
Fetch checkoutUrl from the cart
-
Redirect the customer to Shopify’s hosted checkout
-
Order is placed successfully
After the order is completed, on the order status/thank-you page, when the customer clicks “Continue Shopping”, it redirects back to the default Shopify online store, but I want it to redirect to my custom storefront URL instead.
Constraints:
-
I am not on Shopify Plus
-
I’m using a custom storefront, not the Online Store theme
-
Checkout is Shopify-hosted (not fully custom)
My questions:
-
Is it possible to change or override the Continue shopping redirect URL for non-Plus stores?
-
Are there any supported approaches using:
-
If this is only possible on Shopify Plus, what is the recommended workaround for non-Plus headless storefronts?
Any guidance or best practices for this scenario would be really helpful.
Thanks in advance!
Hi @antony_rufus! The good news is there’s a standard solution for this - the Hydrogen redirect theme. Despite the name, it works for any headless storefront (not just Hydrogen), including Next.js or custom TypeScript setups like yours.
This is a lightweight Liquid theme you install on your Shopify store that handles client-side redirects from your .myshopify.com domain to your custom storefront. This includes the “Continue Shopping” button on the order status page, plus any other traffic that lands on the Shopify-hosted domain.
This was addressed in a previous thread where the developer confirmed it worked for their Next.js setup. The dev docs also cover this in the redirect traffic guide - the key bit is that after going live with a headless storefront, your online store remains active at {shop}.myshopify.com, so you need the redirect theme to catch visitors and send them to your custom domain.
To set it up, download the theme from the GitHub repo, upload it to your store, and publish it. The theme’s theme.liquid file handles the redirection logic automatically. You don’t need Plus for this - it works on all plans.
Let me know if you run into any issues getting it set up.
Hi Dónal,
Thanks a lot for the suggestion! I tried the Hydrogen redirect theme, and it’s working perfectly for my custom storefront. The Continue Shopping redirect now behaves exactly as expected.
Really appreciate the clear explanation and guidance — this was very helpful. Thanks again!
1 Like