Shopify CLI “theme serve” returns: “You are not authorized to edit themes…” on newly created development stores. Shopify CLI is a developer tool; theme serve previews a local theme against a store.
Root cause and constraints:
On development stores, only the store owner can edit themes; staff accounts, even with theme permissions, cannot (per Shopify docs).
Being logged into the wrong store or a stale CLI session can trigger the error.
Fixes confirmed by multiple users:
Log out of Shopify CLI and log back in, explicitly targeting the correct store (e.g., shopify login --store your-store.myshopify.com); verify with shopify whoami.
Ensure you are the store owner when using a development store.
Fully initialize the store: first visit https://your-store.myshopify.com/admin in a clean browser (no cookies), complete any first-time setup prompts, then run shopify login --store and shopify theme serve.
Resources:
Shopify Getting Started docs (notably the “Caution” block).
A linked YouTube video walkthrough; several confirmations that these steps resolved the issue.
Status: Generally resolved for most after re-authentication and correct store/owner setup; one report persisted until completing admin setup in a fresh browser.
PS D:\learn-dawn> shopify theme serve
X You are not authorized to edit themes on kidszone-theme.myshopify.com.
Make sure you are a user of that store, and allowed to edit themes.
Make sure if this is a development store, you are logged in as a store owner. Since the staff members can not edit the themes on the development stores as per Shopify’s documentation. Please try logging in using the store owner account. Please read this link for more details: https://shopify.dev/themes/tools/cli/getting-started
The steps described in this video solved my issue, thanks, i.e. log out everywhere, log back in, making sure to the correct store (as store owner in my case), and I had access to edit theme.
The error was when I had created the store the first time; I was logging through the application. As this option and I didn’t access it for the first time through this link {shop}.myshopify.com/admin
Apparently, the app did not achieve to complete all the configuration, so I needed to open this link in another browser without cookies logging {shop}.myshopify.com/admin and then, logging there, this application asked me for multiple things about connecting with the new storage. and finally, I made shopify login --store {shop}.myshopify.com on the terminal, and then shopify theme serve