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.