---
title: Shopify Development
published: true
index: 10
---

# Shopify development previews

Use Shopify development with real store data by default, including for “run locally.” Use simulation only when explicitly requested. CLI previews upload files; setup needs authenticated command execution, a persistent process and browser access outside read-only report evaluation.

## Resolve source, destination, and authorization

1. Resolve the exact store from the user or unambiguous repository configuration, never ambient login. Read repository guidance and record the revision, dirty changes, merchant settings and build artifacts to include.
2. Inspect existing processes and task artifacts. Reuse a preview only when source/changes, store, theme ID/role, ownership and browser access match. Preserve other tasks' listeners and themes.
3. Check installed CLI help, environment/TOML targeting and the store's read-only inventory. A fresh directory does not establish a fresh development context. Keep credentials and secret-bearing configuration private.
4. Copy the complete intended artifact into a disposable workspace. Preserve merchant settings and unrelated work; do not pull remote settings over source or enable Theme Editor sync incidentally.
5. Before upload, establish the command, store, source scope, destination and replacement behavior. Honor existing explicit/standing authorization covering that action; otherwise request it after preparing the artifact. Login or read access alone is insufficient.

```sh
shopify theme list --store <store>.myshopify.com --json
```

Target only an owned development theme outside scheduled/active experiments. Never overwrite live, control, unrelated or experiment-serving themes. If an existing default development theme has unknown ownership, use an isolated context only after verifying support in installed `theme dev` help; otherwise stop with that blocker. Flags supported by another command may not apply.

## Start and verify

Resolve or clear inherited targeting/environment/live-write flags for this invocation without changing persistent configuration. Use installed-version flags, never `--allow-live`, and avoid secret-bearing verbose logs.

When the default destination is absent or owned and its creation/replacement is authorized:

```sh
shopify theme dev --store <store>.myshopify.com --path <absolute-disposable-theme-path>
```

Pin a verified owned development theme when reusing it:

```sh
shopify theme dev --store <store>.myshopify.com --path <absolute-disposable-theme-path> --theme <verified-development-theme-id>
```

Use the host's managed process facility and a free port. Verify that the intended browser can reach the execution host through protected access or the returned Shopify preview link; never expose private source through an unauthenticated public tunnel.

Read actual local, editor and share URLs from readiness output. Read back store, theme ID and role and bind them to the process/source. Preserve route preview parameters and keep secret-bearing URLs in private task artifacts.

Open actual routes in a browser supported by the endpoint. Check expected content, desktop/mobile rendering, affected anonymous controls, browser errors and sync diagnostics. Sync success alone does not prove browser readiness or theme identity. Local development does not support checkout customizations; use independently verified supported preview evidence or record the gap.

When supplied edits change, refresh the disposable copy, wait for sync and retest affected assertions. Record the final revision/changes, filters and generated-asset differences; this skill does not author edits.

## Handoff, failures, and cleanup

Return source/store/theme ID/role, CLI version, verified URLs/routes/states/viewports, expected and observed results, evidence, process owner, lifetime, limitations and stop instructions. Keep requested interactive previews running when supported. Verify the local or Shopify-hosted link actually being handed off.

Recheck assertions after source/merchant drift or resync, retaining prior evidence identities. On interrupted or ambiguous uploads, inspect process state and remote inventory before retrying the same owned destination. Preserve verified partial artifacts; missing source parity, ownership, access or browser routing remains a specific blocker.

On failure, cancellation or stop, close only owned processes and temporary access. Remote deletion needs authorization and verified ownership; never delete themes or run `shopify auth logout` as routine cleanup. Development themes expire after seven days of inactivity or logout; report that lifetime. Persistent unpublished uploads are a separate authorized operation.

## Sources

Verified 2026-10-22; recheck installed help and official documentation when changing flags or lifecycle guidance.

- [Shopify CLI for themes](https://shopify.dev/docs/storefronts/themes/tools/cli)
- [Theme dev: upload, replacement, preview links, and flags](https://shopify.dev/docs/api/shopify-cli/theme/theme-dev)
- [Theme list: exact-store theme inventory](https://shopify.dev/docs/api/shopify-cli/theme/theme-list)
