Re: Turn off Shopify storefront when using headless

Turn off Shopify storefront when using headless

1 0 0

I've set up a headless Shopify store using Nextjs and my own domain at I'm using Shopify storefront api to create a checkout and redirecting my customers to there. My problem is that my existing shopify storefront (that I don't use) is still available at How do I remove this storefront? Note: this is also an issue because if a customer clicks on the Art-Ificial text in the top left corner on the Shopify checkout, it will take them to (the unused storefront) and not (the real store pulling + displaying products using storefront api).

Reply 1 (1)

Shopify Partner
1 0 0
I added a workaround that:


1. Hides all content on the Shopify Store

2. Shows a "Please wait..."

3. Redirects to the custom store after 1 second.


Add the below snippet to the theme.liquid when editing code in Shopify
<!-- START -->
<style type="text/css">
body > * {
display: none !important;
body:after {
content: "Please wait...";
position: absolute;
left: 0;
top: 0;
width: 100%;
height: 100%;
text-align: center;
padding: 20px;
z-index: 111;
<script type="text/javascript">
setTimeout(() => {
window.location.href = "";
}, 1000);
<!-- END -->