Go to homepage 2sh

Harbor

Architectural exploration and reference rebuild of a high-volume DTC brand: decoupling Shopify with Storefront API, Astro, and Storyblok to eliminate app-bloat overhead while keeping native checkout, inventory, and PCI compliance intact.

view the live build
Harbor Autumn / Winter 26 featured drop with edge-cached product cards
client
Reference Architecture
service
Shopify Storefront API + Astro + Storyblok
sector
DTC Apparel / Omnichannel Retail
year
2026

the brief

Harbor is modelled on the technical profile of a high-volume sustainable DTC apparel merchant doing eight figures on Shopify — gingham and botanical prints, oversized collars, small-batch seasonal drops — the kind of brand where dozens of app scripts choke mobile conversion and every campaign drop requires fragile Liquid workarounds.

built with

Astro · Storyblok · Shopify Storefront API · Cloudflare Workers

what changed

Decoupling the frontend strips 890 KB of app script bloat without sacrificing commerce back-office workflows.

A typical growing Shopify store accumulates twelve to twenty apps over two years: review widgets, size guides, loyalty programs, upsells, and cross-sells. Each app injects render-blocking JavaScript into the Liquid theme. Harbor moves all product and collection rendering to Astro at the edge, querying the Shopify Storefront API at build time and on webhook invalidation, cutting initial client JavaScript from 890 KB down to zero.

Native Shopify checkout, inventory management, tax calculations, and fulfillment routing remain untouched. The customer browses an instant, edge-cached editorial storefront and transitions to Shopify's hardened, PCI-compliant checkout domain to complete the purchase.

inside the build

the app-bloat tax

Every successful DTC brand starts on a standard Shopify Liquid theme. It is fast to launch, affordable, and requires minimal technical overhead.

As the brand scales past €10M in annual GMV, the frontend quietly deteriorates. The merchandising team adds a loyalty program, a size recommender, product reviews, a currency switcher, a countdown banner, and half a dozen tracking pixels. Each app appends its own bundle of un-optimized JavaScript to theme.liquid.

Within eighteen months, the homepage and product detail pages are loading 25 to 35 third-party scripts, dragging mobile Largest Contentful Paint past 4.9 seconds. On mobile devices—where 75% to 85% of paid social traffic lands—buyers bounce before product photography renders, quietly eroding return on ad spend.

headless without the headless headache

Most headless commerce migrations fail because agencies attempt to rewrite everything from scratch, building custom cart logic, payment gateways, and inventory sync engines.

Harbor uses a disciplined decoupling boundary:

  1. Storefront delivery: Astro pre-renders catalog pages, editorial lookbooks, and campaign landing pages into pure static HTML/CSS, distributed across Cloudflare’s global edge network.
  2. Visual merchandising: Storyblok provides the marketing team with a visual drag-and-drop editor for homepages, collection features, and editorial drops—with no Liquid theme editing or developer tickets.
  3. Commerce engine: Shopify continues to do what it does best. Inventory counts, customer accounts, promo codes, tax calculations, and native Shopify Checkout remain fully managed on Shopify’s battle-tested infrastructure.

Cart interactions use a lightweight client island (under 4 KB) communicating directly with Shopify’s Storefront Cart API. When the buyer clicks “Check Out”, they land on Shopify’s native, PCI-compliant checkout.

15-minute campaign drops

Seasonal collections, influencer collaborations, and flash sales are the lifeblood of DTC revenue. On bloated Liquid themes, building a custom landing page means fighting theme sections, conflicting CSS classes, and slow preview deploys.

With Storyblok structured components mapped directly to Astro layouts, the merchandising team builds bespoke campaign landers the morning of a launch. Assets, copy, product embeds, and variant pickers are configured visually. Publishing invalidates Cloudflare edge cache tags in under 15 milliseconds—with zero build queues and zero engineering involvement.

For brands spending €50k to €200k a month on Meta, TikTok, and Google Shopping, mobile load speed is a direct revenue lever. Every 100ms improvement in page load measurably increases add-to-cart rates and lowers cost per acquisition.

Harbor delivers full product detail pages in 0.78 seconds on throttled 4G connections. Instant page loads mean paid ad clicks land on vibrant product photography instead of blank layout shifts, maximizing return on every acquisition dollar.

flat bills during holiday spikes

Black Friday, Cyber Monday, and high-profile press features expose traditional stores to sluggish response times and third-party script timeouts.

By serving static assets and pre-rendered catalog pages directly from Cloudflare’s edge cache, Harbor achieves a 99.1% edge cache hit ratio. Traffic surges do not touch origin compute, ensuring consistent sub-second speeds throughout peak sales events while infrastructure costs remain flat.

the benchmark numbers

Metric Legacy Shopify (App-Bloated Liquid) Harbor (Astro + Storefront API) Delta
Mobile LCP (throttled 4G) 4.92s 0.78s -84.1%
Initial client JavaScript 892 KB 0.0 KB (2.9 KB cart island, gz) -99.7%
Lighthouse mobile score 42 / 100 99 / 100 +57 pts
Third-party app scripts 16 render-blocking scripts 0 on critical path Main thread cleared
Campaign drop turnaround 3–5 days (agency tickets) 15 minutes (direct in CMS) Same-day merchandising
Edge cache hit ratio 0% (Shopify dynamic SSR) 99.1% (Cloudflare edge) Instant global delivery
Checkout & PCI compliance Native Shopify Checkout Native Shopify Checkout 100% compliant, zero risk

in the details

02 views
Harbor zero-JS product grid with edge-cached Storefront API data
Harbor zero-JS product grid with edge-cached Storefront API data
Harbor campaign landing page with Storyblok visual merchandising
Harbor campaign landing page with Storyblok visual merchandising

the result

Sub-second mobile delivery protects paid ad conversions across Meta and TikTok, turning paid acquisition traffic into completed checkouts before buyers bounce.

Decoupling visual merchandising into Storyblok gives e-commerce leads drag-and-drop autonomy for campaign drops and collection launches, while Shopify continues to quietly handle cart, checkout, inventory, and PCI compliance.

credits

Two Shells

Systems Engineering

building something similar?

talk to 2sh