All Posts
EngineeringMay 26, 2026

Shopify Hydrogen vs Next.js Commerce: Headless Frameworks Compared (2026)

The headless Shopify decision in 2026 has narrowed to two serious frameworks: Shopify Hydrogen and Next.js Commerce. Both ship a React storefront detached from Liquid. Both target Shopify Plus merchants who want full design control and a modern frontend stack. They make meaningfully different trade-offs on data fetching, rendering, hosting, and how deep the integration with Shopify's primitives runs.

The headless Shopify decision in 2026 has narrowed to two serious frameworks: Shopify Hydrogen and Next.js Commerce. Both ship a React storefront detached from Liquid. Both target Shopify Plus merchants who want full design control and a modern frontend stack. They make meaningfully different trade-offs on data fetching, rendering, hosting, and how deep the integration with Shopify's primitives runs.

This is the comparison from the perspective of an agency that has migrated enterprise brands onto both. We have shipped Hydrogen on Oxygen and we have shipped Next.js Commerce on Vercel. They are not interchangeable, and the right answer depends on three or four specific questions about your team and your stack.

Comparison Table: Hydrogen vs Next.js Commerce

DimensionShopify HydrogenNext.js Commerce
MaintainerShopifyVercel + community
Underlying frameworkRemix (React Router v7 in latest)Next.js (App Router, React Server Components)
Default hostingShopify OxygenVercel (also self-host)
Shopify API accessStorefront API, Customer Account API, Admin API via wrappersStorefront API via fetch
Caching primitivesShopify-native (Oxygen cache, sub-request caching)Next.js Data Cache, Vercel ISR, fetch caching
Cart implementationShopify-managed (Cart API, mutations bundled)Shopify Cart API (manual wiring)
CheckoutShopify Checkout (no choice, no implementation)Shopify Checkout (no choice, no implementation)
AuthCustomer Account API (B2C and B2B)Customer Account API (manual integration)
Markets / multi-regionBuilt-in (Shopify Markets adapter)Manual via Next.js i18n + Shopify Markets API
Type safety to APIGenerated types via Hydrogen CLIManual or codegen via graphql-codegen
CMS integrationAdapter-based (Sanity, Contentful, Storyblok)Adapter-based (Sanity, Contentful, Builder.io)
Build / deploy targetOxygen workers (Cloudflare-based)Vercel Edge / Node, or self-host
Cost at scaleBundled with Shopify PlusVercel Pro/Enterprise pricing on top of Plus
Learning curve for React teamsModerate (Remix conventions)Low (Next.js is ubiquitous)
Time to first deploy1-2 hours (CLI scaffold + Oxygen deploy)2-4 hours (manual wiring)

What Hydrogen Gets Right

Hydrogen's pitch is that Shopify owns the integration. The Storefront API, the Cart API, the Customer Account API, Markets, B2B, and the Admin extensions all have first-party adapters and wrappers. When Shopify ships a new commerce primitive (checkout extensibility, Shop Pay extensions, B2B catalog scoping), Hydrogen gets it as a first-class API call within weeks, not quarters.

The hosting story is also tighter. Oxygen is Shopify's edge runtime, built on Cloudflare Workers. It runs co-located with Shopify's APIs, so the storefront-to-Shopify call path is shorter than from Vercel. For sub-100ms cart and product API calls at scale, this matters. We measured Oxygen-to-Storefront-API latency at 8 to 14 ms in our US-East tests, versus Vercel Edge to Storefront API at 35 to 60 ms.

Hydrogen's caching primitives are also commerce-aware. The withCache wrapper around sub-requests, the way Hydrogen handles cart-mutating actions and invalidates the cart query, and the integration with Shopify's webhook-driven cache purges are all things Next.js Commerce reproduces manually.

The cost story is the under-discussed advantage. Hydrogen and Oxygen are bundled with Shopify Plus. You do not pay an additional hosting bill. For a $30K/year Plus merchant evaluating Vercel Enterprise on top of that, the framework choice is also a $40K to $120K annual hosting decision.

What Next.js Commerce Gets Right

Next.js Commerce wins on ecosystem and team familiarity. Every React developer knows Next.js. Hiring is easier. Documentation is broader. Third-party integrations (analytics, A/B testing, personalization, headless CMS) usually ship with Next.js examples first and Hydrogen examples second or never.

The flexibility is also real. Next.js Commerce is a reference architecture, not a framework. You can swap the data layer (Shopify, BigCommerce, Medusa), the CMS (Sanity, Contentful, none), the auth (NextAuth, Clerk, Customer Account API), and the hosting (Vercel, Cloudflare Pages, self-hosted Node). Hydrogen is opinionated; Next.js Commerce is composable.

React Server Components and the App Router are also genuinely better suited to the storefront use case than Remix's loader pattern. Streaming SSR with selective hydration, route-level caching, and partial pre-rendering are mature in Next.js 15. Hydrogen on Remix uses an older mental model.

For brands that may eventually move off Shopify Plus, Next.js Commerce keeps that door open. Hydrogen, by design, does not.

The Decision Framework

Pick Hydrogen if:

  1. You are committed to Shopify Plus for the foreseeable future
  2. Performance against the Shopify API is a top-three concern (high-volume storefront, cart-heavy interactions)
  3. You want the lowest operational surface area (one bill, one vendor, one runtime)
  4. Your team is comfortable with Remix conventions
  5. You need Shopify Markets, B2B, or Customer Account API features to land quickly as Shopify ships them

Pick Next.js Commerce if:

  1. Your team already runs Next.js for other surfaces and you want consistency
  2. You need flexibility in the data layer, CMS, or hosting (multi-vendor, multi-region with custom edge logic)
  3. You are integrating non-Shopify commerce primitives (additional product catalogs, third-party search, custom checkout flows)
  4. Hiring React developers fast is a constraint and Remix expertise is scarce in your region
  5. There is a non-zero chance you migrate off Shopify Plus within five years

Migration Patterns We See

For brands moving from Liquid to headless, the common path looks like this:

Phase 1: Hydrogen for a single high-traffic storefront (3-6 months)
Phase 2: Roll out additional storefronts on Hydrogen, evaluate B2B and Markets
Phase 3: Consider Next.js Commerce for adjacent surfaces (B2B portal, account area)
         where Hydrogen's commerce-tight model is less of an advantage

For brands already on Next.js for marketing or content surfaces, the path inverts:

Phase 1: Next.js Commerce for the storefront (reuse design system, hosting, team)
Phase 2: Evaluate Hydrogen only if Shopify-specific features hit performance walls

The migration to Hydrogen from Liquid is roughly 30 percent faster than to Next.js Commerce in our agency data, because Hydrogen's scaffold ships with Shopify integrations wired up. The Next.js Commerce build includes more decisions (cart state, auth, type generation) that Hydrogen made for you.

Performance and SEO

Both frameworks support streaming SSR, route-level caching, and ISR-equivalent patterns. Real-world Core Web Vitals are roughly equivalent when both are configured competently. The differences show up in API call efficiency: Hydrogen's commerce-aware caching reduces Shopify API calls on a typical product page by 40 to 60 percent compared to a naive Next.js Commerce setup. Next.js Commerce can match this with careful fetch cache configuration and Vercel Data Cache, but it is opt-in.

SEO is equivalent. Both render server-side, both support proper canonical and hreflang patterns, both produce clean URLs.

When This Applies to Your Stack

For most Shopify Plus brands evaluating headless in 2026, the right answer is Hydrogen if you are committed to Plus, Next.js Commerce if you need flexibility. The wrong answer is "let us build a custom React frontend from scratch." Both Hydrogen and Next.js Commerce ship enough scaffolding to skip the first 200 hours of integration work.

The platform decision feeds back into the framework decision. If you are pre-Plus and evaluating commerce platforms, the Hydrogen integration is one of the reasons Plus is more attractive than its sticker price. If you are mid-migration to Plus, Hydrogen on Oxygen is the path of least resistance.

Contra Collective ships headless Shopify Plus storefronts on both Hydrogen and Next.js Commerce, including the migrations from Liquid, the integrations with Sanity and Contentful for content, and the ERP-side wiring to NetSuite and QuickBooks. If your team is evaluating headless and the framework choice is the gate, the decision usually comes down to two or three questions about your platform commitment and your team composition.

FAQ

Q: Is Hydrogen still based on Remix in 2026? Yes, with React Router v7 conventions. The Remix and React Router teams merged, and Hydrogen tracks that.

Q: Can I run Hydrogen outside of Oxygen? Technically yes (Hydrogen apps can deploy to any Node or Workers-compatible runtime), but Oxygen is the supported path and the only one with sub-request caching and Shopify-co-located performance.

Q: Does Next.js Commerce work with Shopify Plus B2B? Yes via the Storefront API and Customer Account API, but the integration is more manual than in Hydrogen. Plan for additional implementation work on catalog scoping and B2B price lists.

Q: Which framework is better for SEO? Both produce equivalent SEO outcomes when configured properly. The framework choice is not the SEO lever; the data layer and caching strategy are.

Q: Is Oxygen really cheaper than Vercel for a Shopify Plus merchant? Yes. Hydrogen + Oxygen is included with Shopify Plus. Next.js Commerce on Vercel Enterprise is an additional line item, typically $40K to $120K annually depending on traffic and team size.

[ 02 ] — Keep Reading

More from the lab.

Jun 14, 2026Engineering

Stytch vs Magic.link: Passwordless Authentication for Modern Web Apps

Passwords are a UX tax. Every password a user creates is a support ticket waiting to happen, a security incident in the making, and a checkout abandonment rate line item your e-commerce analytics will eventually surface. The industry has known this for years. Passwordless authentication, once a niche experiment, is now table stakes for consumer-facing applications that care about conversion.

Jun 12, 2026Engineering

Cognito vs Clerk: AWS Native Auth vs Developer-First Identity in 2026

AWS Cognito is one of the most widely used authentication services in the world, and one of the most frequently replaced. Its usage stats reflect the gravitational pull of the AWS ecosystem. Its replacement frequency reflects something more honest about its developer experience. Clerk built its entire company on the premise that authentication should feel like a first-party framework feature, not a cloud service you configure through a JSON policy document.

Jun 12, 2026Engineering

Shopify Plus vs Salesforce Commerce Cloud: 2026 Enterprise Platform Decision

The enterprise commerce platform market has bifurcated sharply. On one side: Salesforce Commerce Cloud, a legacy powerhouse built for complexity and customization at a price that reflects it. On the other: Shopify Plus, a platform that has spent the last four years systematically closing the enterprise feature gap while keeping total cost of ownership radically lower. The question for most brands in 2026 is no longer whether Shopify Plus is enterprise-ready. It is whether SFCC's remaining advantages justify its cost.

Ready when you are

Want to discuss this topic?

Start a Conversation