CONTACT US
TABLE OF CONTENTS

Migration from Webflow to Sanity CMS step by step

Chris Lojniewski
By Chris LojniewskiUpdate:
Text reading NEXT.JS MIGRATION FROM WEBFLOW TO SANITY with a glowing red atom icon and the Pagepro logo on a dark background.

TL;DR

  • Webflow Interactions do not carry over to a new frontend, so list every animation in the audit and rebuild the ones worth keeping.
  • Webflow’s code export includes HTML, CSS, JavaScript, and assets, but not your CMS items, so collection content has to come out separately.
  • The Webflow Data API returns reference and multi-reference fields as item IDs, images as objects with a URL and alt text, and rich text as HTML.
  • Import standalone documents such as categories and authors first, then create the documents that reference them, and run every script against a separate dataset first.
  • Map every old URL that changes to its new address with a permanent redirect; on Vercel, next.config.js holds up to 1,024 redirects.
  • Switching DNS starts the technical validation: crawl the new site, submit every form, submit the new XML sitemap and watch 404 logs for several months.

Should you migrate from Webflow to Sanity?

A Webflow-to-Sanity migration makes sense when your site’s visual presentation still works, but its content structure, editorial workflow, and frontend flexibility have become restrictive. Webflow links hosting, styling, and content in one visual canvas, which suits self-contained sites. Sanity treats content as structured data in code-defined schemas, separate from presentation, so one source can feed many frontends.

For a CTO, the move is an architecture decision as much as a CMS swap: your team takes on a frontend codebase, hosting and an API layer that Webflow used to bundle, in exchange for control over the content model, the build and every integration. The risk concentrates in two places, the content model and search rankings at launch, and this guide covers both.

Several operational signals show a team is ready to move beyond Webflow:

  • Multi-channel delivery: Webflow ties CMS output to its hosted templates, whereas Sanity serves structured content to web apps, mobile clients, and feeds through APIs.
  • Editorial governance: Sanity Studio lets engineering teams add validation rules, scheduled publishing, and custom editing workspaces when a visual canvas limits content operations.
  • Frontend control: Pairing Sanity with Next.js or Astro gives you control over builds, caching, and integrations with other services.

Migrating does not mean abandoning your design. You can keep layouts, brand identity, and content priorities while moving to a composable stack that is easier to extend. For the signs that a site has outgrown Webflow in more detail, see when outgrowing Webflow means it’s time to migrate.

When it is better to stay on Webflow

A headless architecture adds engineering overhead that not every website justifies. Staying on Webflow is usually the smarter decision when:

  • The site is small and rarely changes: A few dozen marketing pages with infrequent updates rarely justify API maintenance, separate hosting, and a frontend pipeline.
  • The problems are editorial, not technical: A new platform does not fix unclear approvals, missing guidelines, or disorganized assets.
  • The relaunch date is fixed and close: Migrating without a data and schema audit risks broken references, lost metadata, and ranking drops.

What changes when you move to a headless CMS

Moving from an all-in-one builder to a headless CMS changes how you store, edit, and distribute content. In Webflow, authoring, schema design, and presentation share one visual workspace. Sanity separates them: content stops being pre-rendered page components and becomes structured data stored independently of any design, which an API serves to websites, apps, and portals alike.

That makes the migration a translation into a portable content model, not a copy-paste exercise. Static text blocks, collection fields, and template-locked assets have to be broken down into reusable documents and references. Once they are, engineering can modernize the frontend freely while marketing keeps control of the content.

Webflow vs Sanity: editing, cost, and performance

Comparing Webflow with Sanity means looking past CMS feature tables, because the two take opposite approaches to editing, cost, and speed. Webflow edits on the rendered page and bundles hosting into its plans. Sanity edits in a structured Studio, prices by seats and usage, and leaves hosting and performance to the frontend you build.

Webflow lets editors change copy and layouts directly on the canvas. Sanity Studio is a standalone React workspace that developers shape around your publishing workflow, with custom previews, nested document structures, field-level validation, and real-time collaboration. Editors trade drag-and-drop on the page for structured inputs, modular blocks, and live previews of their drafts.

Performance depends on execution, not architecture alone. A headless frontend avoids builder-generated scripts and gives you control over assets, but poor caching, unoptimized queries, or heavy client-side JavaScript can produce Core Web Vitals worse than a clean Webflow site.

Break free from visual builder limits. Own your stack.

Choosing between Next.js and Astro for the frontend

Sanity delivers content through an API and renders no pages, so the frontend framework shapes delivery speed and development effort. Next.js fits when the marketing site connects to an application layer, such as customer portals, configurators, or logged-in accounts, or shares React components with an existing product; its on-demand revalidation, triggered by Sanity webhooks, puts published edits live without a full rebuild, and Vercel runs it with no extra setup. Astro fits content-heavy sites with little interactivity: its islands architecture ships no client-side JavaScript by default and hydrates only interactive elements. Either way, speed comes from disciplined asset budgets and sensible caching, not the framework badge.

How to prepare for a Webflow to Sanity migration

A reliable migration starts with an audit before anyone writes a schema or an export script. Skipping it leads to orphaned assets, dropped tracking, and broken references. Audit three areas and record the results in one sheet that the content model, the import scripts and the redirect map are all built from:

  • Content and schema catalog: List static pages, CMS collections, reference fields, and media files, and decide whether drafts and localized variants have to move.
  • SEO assets and URL hierarchy: Record every production URL, its canonical, title, description and Open Graph image, plus the redirects already set in Webflow’s site settings.
  • Third-party scripts and interactions: Document Webflow forms, analytics triggers, tag managers, and consent scripts, and list every Webflow Interaction (scroll and hover animations, page transitions), so developers can rebuild them in the new frontend and estimate that work.

Migration from Webflow to Sanity step by step

A Webflow to Sanity migration works best as a staged rollout rather than one data dump: model the content, export it, transform and import it, then rebuild the frontend. Prove the pipeline on one contained collection first, such as team profiles or company news, so field transformations, asset downloads, and schemas are tested at low volume before the complex collections.

Scripts can scan collections, parse field types, and draft starter schemas, but they cannot judge editorial intent. A person still has to check that multi-reference fields link correctly, that text splits into the right fields, and that rich text maps cleanly into Portable Text.

Step 1: model your content in Sanity

Content modeling in Sanity structures data around what content is, not how a Webflow template shows it. Copying Webflow collections one-to-one carries their layout constraints into rigid fields. Instead:

  • Shared entity references: Create separate documents for authors, categories, and other shared entities, and link them with reference fields so they never drift out of sync.
  • Independent documents: Pull team directories or location listings that were hardcoded in page templates into their own queryable document types.
  • Modular blocks: Break static page layouts into a defined set of content blocks, so marketing can compose pages within brand rules.

Step 2: export Webflow CMS data and media

Webflow’s code export includes HTML, CSS, JavaScript, and assets, but not your CMS items, so collection content has to come out separately. Each collection can be exported as a CSV file, but for a scripted migration the Webflow Data API is more reliable: it returns reference and multi-reference fields as item IDs, images as objects with a URL and alt text, and rich text as HTML. Keep every Webflow item ID, because those IDs are the keys you use to rebuild author, category and other references in Sanity.

Static pages outside the CMS, such as the home page and landing pages, need their own route: the Data API’s page content endpoint returns their text, images and component content as nodes, which you map into page documents in Sanity, or you rebuild them by hand when there are only a few. If the site uses Webflow Localize, each secondary language is read with its own locale ID; requests without one return only the primary locale.

Before you import, check the exported data: rich text contains inline HTML to convert, including any embeds or custom code, and some multi-reference values may be empty. Images are still hosted on Webflow’s CDN, so download every asset and verify each URL resolves before you cancel the Webflow site plan.

Step 3: transform and import into Sanity

Write a transformation script with the Sanity client or Sanity’s migration tooling that turns Webflow items into Sanity documents. It maps plain fields to Sanity types, converts HTML rich text into Portable Text (the @portabletext/block-tools package handles the HTML conversion), and keeps a table of Webflow IDs and their new Sanity IDs. Run it in passes:

  • Assets first: Upload images to Sanity from their Webflow URLs, carrying over alt text, so editors can later set hotspots for responsive crops.
  • Two-pass linking: Import standalone documents such as categories and authors first, then create the documents that reference them.
  • Test dataset first: Run every script against a separate dataset, check the Portable Text output and references, and only then import into production.

Step 4: rebuild the frontend and editing experience

With the content in Sanity, the work moves to the presentation layer and the editing interface. Templates become components that fetch exactly the fields they need with GROQ queries, which keeps payloads small:

  • Design tokens: Tie colors, type scales, and spacing to reusable components that match your Sanity schemas.
  • Constrained page builders: Offer a curated set of sections, such as heroes, grids, and testimonials, so editors build pages without breaking brand rules.
  • Live preview: Connect Sanity’s Presentation tool to the frontend, so editors see drafts on the real site before publishing.
  • Interactions and animations: Webflow Interactions do not carry over to a new frontend; rebuild the ones from your audit list in CSS or an animation library, and drop the ones nobody would miss.

On Darktools, a WordPress site Pagepro rebuilt on Next.js and Sanity in four weeks, editors now manage pages with a page builder and live preview without a developer.

Webflow to Sanity redirects and SEO continuity

Protecting rankings in a Webflow to Sanity migration comes down to stable URLs, preserved metadata, and pages crawlers can read in full. Search engines expect the same addresses, titles and response codes after launch as before, so plan these three areas from the audit sheet onward, not in the last week before the DNS switch:

  • Permanent (301/308) redirects: Map every old URL that changes to its new address with a permanent redirect. On Vercel, next.config.js holds up to 1,024 redirects, and larger maps belong in Vercel bulk redirects or in redirect documents in Sanity that editors can manage.
  • Metadata and structured data: Move titles, descriptions, and Open Graph images into dedicated SEO fields, and generate JSON-LD and the XML sitemap from Sanity content.
  • Server rendering and staging access: Serve fully rendered HTML, not client-rendered shells, and keep staging out of the index with password protection or a noindex header. Vercel adds X-Robots-Tag: noindex to preview deployments by default, but not to a custom staging domain, which needs its own guard.

Pagepro moved GP Notebook, a medical reference platform with more than 100,000 subpages, from a legacy custom CMS to Next.js and Sanity, and its organic traffic doubled within two years of the relaunch. For the full SEO side of a platform move, see the headless CMS SEO migration guide.

Outgrown Webflow? Upgrade to an enterprise-grade stack.

Pitfalls to avoid in a Webflow to Sanity move

Most failed Webflow to Sanity moves come from treating Sanity like a site builder or from forgetting the functional glue that held the old site together. A headless setup gives teams freedom, but nothing in it rebuilds forms, tracking or a sensible content model for you. Watch for these three mistakes:

  • Copying Webflow collections verbatim: It carries template restrictions into the new model; schemas should reflect what the content is.
  • Forgetting forms, tracking, and consent: A new frontend does not inherit Webflow’s form handling or analytics, so each needs its own endpoint or script.
  • Trusting automated imports unchecked: Scripts mangle rich text and nested arrays, so review the converted Portable Text page by page.

Launch checklist and post-migration QA

Switching DNS starts the technical validation rather than ending the project, because live traffic and real crawlers expose routing edge cases, script conflicts and integration gaps that staging missed. Run a structured check in the first days after cutover and keep monitoring for several months, until rankings and 404 logs settle at their pre-launch levels:

  • Crawl and tracking audit: Crawl the new site for broken links, submit every form, and check that analytics events fire.
  • Sitemap and indexing: Check robots.txt and canonicals, and submit the new XML sitemap in Google Search Console.
  • Ongoing monitoring: Watch 404 logs, rankings, and crawl activity for several months and fix route regressions as they appear.

Pagepro, a Sanity development agency, runs migrations to Sanity on Nexity, its own Next.js and Sanity framework, built from 20+ real projects with zero drops in Google rankings across all of them. To see your content on it before you commit, Pagepro offers to rebuild part of your website with your real content in 48 hours, with no cost and no commitment.

FAQ

Should I migrate from Webflow to Sanity if my site still looks good?

Yes, if your content structure and editorial workflows have become restrictive. You can keep your design and brand while moving to a composable stack. Migration pays off when you need multi-channel delivery, stronger editorial governance, or a frontend you control, built with a framework like Next.js.

When is it better to stay on Webflow instead of going headless?

Stay on Webflow if your site is small and rarely updated, or if a non-technical team relies on visual drag-and-drop editing. Headless adds engineering overhead, separate hosting costs, and complexity that a simple marketing site may not justify.

How does the cost of Sanity compare to Webflow pricing?

Webflow bundles hosting, CDN, and CMS storage into its site plans, with Premium at $25 per month billed yearly as of October 2026. Sanity charges $15 per seat per month on its Growth plan, with metered overages above the quotas. Unlike Webflow, hosting is not included, so budget separately for frontend hosting on a platform like Vercel and for developer time.

How long does a Webflow to Sanity migration take?

On Nexity, Pagepro’s Next.js and Sanity framework, a production-ready foundation takes about four weeks: content migrated, core journeys working and editors trained. Many locales, custom Webflow Interactions, extra integrations and advanced features add time; they are scoped after the foundation is in place, not promised inside the four weeks.

Why isn’t a headless Sanity site automatically faster than Webflow?

Because performance depends on execution, such as caching rules and query design. A headless site avoids builder-generated scripts, but heavy client-side JavaScript or unoptimized assets can still give it worse Core Web Vitals than a clean Webflow site.

Should I use Next.js or Astro with Sanity after migrating from Webflow?

Choose Next.js when the site connects to application features or shares React components with a product, and Astro for content-heavy sites with little interactivity. Astro ships no client-side JavaScript by default; Next.js adds on-demand revalidation triggered by Sanity webhooks.

How do I export CMS collections and images from Webflow?

Webflow’s code export leaves out CMS items, so export each collection as CSV or, better for scripts, read it through the Webflow Data API, which returns references as item IDs and images with their URLs. Static pages come through the API’s page content endpoint, and every image should be downloaded before you cancel the Webflow site plan.

How do I keep SEO rankings and URLs intact during a Webflow to Sanity migration?

Audit every production URL and its metadata before you build, map each changed URL to a permanent (301 or 308) redirect, and move titles, descriptions and canonicals into SEO fields in Sanity. Serve fully rendered HTML, keep staging out of the index, and submit the new sitemap at launch.

Chris Lojniewski

Chris Lojniewski is the CEO and founder of Pagepro, a software house specializing in Next.js and Sanity migrations. Since 2016 he has helped UK and US companies replace WordPress and other legacy CMS platforms with fast, headless websites. Pagepro runs its migrations on Nexity, its own Next.js and Sanity framework, which delivers a production-ready foundation in about four weeks. Recent work includes a medical platform with 100,000+ pages rebuilt on Next.js and Sanity. Chris is a Vercel v0 Ambassador and a Sanity Pioneer. He writes about CMS migration, headless architecture and AI-assisted development.

Article link copied

Close button

Leave a Reply

* Required informations.