The brief
A growing direct-to-consumer skincare brand had outgrown their Shopify theme. Page-load times had crept past 4 seconds, the content team needed engineers to publish new product stories, and the brand presentation looked increasingly off-the-shelf compared to their competitors. They wanted a custom storefront that felt like the brand, performed beautifully, and let the content team move quickly.
Why headless
Shopify's standard theme model is excellent for getting a store live. It becomes a constraint when the brand presentation needs to be fully custom and performance matters. Headless decouples the storefront (where we have full creative control) from Shopify's commerce backbone (which is excellent at its job).
We picked Astro for the storefront — content-heavy, partially hydrated, edge-deployable. Astro's Shopify integration handled the product data layer cleanly.
What we built
- A custom Astro storefront with a fully bespoke design system that matched the brand's print and social presence.
- Sanity CMS as the headless content layer for product stories, journal entries, and landing pages.
- Shopify as the source of truth for products, inventory, checkout, and orders.
- Cloudflare Pages as the deployment target for global edge performance.
- A custom A/B testing framework using Cloudflare Workers for per-visitor variant assignment.
The performance work
Our performance target was a sub-second TTFB globally and a 95+ Lighthouse score on the product detail page. Hitting that required:
- Static rendering of all marketing and category pages with on-demand incremental updates.
- Aggressive image optimisation — AVIF first, multiple breakpoints, lazy loading below fold, preloading for the hero image.
- A custom font-loading strategy with
size-adjustto prevent CLS. - Cloudflare edge caching for product data with stale-while-revalidate.
The outcome
- TTFB dropped from 1.4s to 280ms globally.
- Mobile conversion increased 38% in the first 60 days post-launch.
- The content team now publishes new product stories without engineering involvement — average time-to-publish dropped from 3 days to 2 hours.
- Brand-perception NPS (measured via on-site surveys) improved noticeably, though we don't claim a clean attribution.
The unexpected upside: the content team's autonomy turned out to be the most valuable outcome. They went from publishing one new story a month to publishing three or four. That cadence change has shaped how the brand now thinks about content.