HubSpot CMS migration
★★★★★ 4.6 CE

HubSpot CMS Migration & Switching Guide 2026

Migrating to HubSpot CMS is a theme rebuild in HubL, not an import, and migrating off keeps the static HTML but not HubL, HubDB, serverless, forms or CTAs.

HubSpot CMS Migration verdict

Verified today·6 sources checked

Migrating to HubSpot CMS is a theme rebuild, and migrating off keeps the static layer but not the dynamic.

Inbound, HubSpot documents recreating a WordPress theme as a HubSpot theme: PHP and hooks become HubL, index.php becomes base.html, and functions.php becomes HubL macros or serverless functions. You then import content.

How to plan the move

Migrate to HubSpot CMS when you want the CMS tied into the HubSpot CRM and you are prepared to rebuild the theme in HubL, not import it. Keep your content master and any critical dynamic logic documented outside HubSpot. While the static theme and HTML export cleanly, the HubL, HubDB, serverless, forms and CTAs do not survive a move off-platform. Budget developer time for the functions.php rebuild, and plan multi-portal moves as export-then-import.

Honest limits
  • Inbound is a theme rebuild, not an import: WordPress PHP and hooks become HubL, and functions.php has no direct equivalent, becoming HubL macros or serverless.
  • The static layer exports well, HTML for pages, posts and templates, HubDB, SEO data and redirects, but the dynamic layer, HubL, serverless, forms and CTAs, stops working off-platform. Serverless functions are Content Hub Enterprise-only on HubSpot's NodeJS runtime, raising both plan tier and lock-in.
  • There is no account-to-account merge, so consolidating portals means export-then-import.
Inbound
Rebuild theme (WP to HubL)
Content export
Broad (static layer)
Dynamic layer
Proprietary (one-way)
Serverless
NodeJS, Enterprise-only
Account merge
Not supported
View sources

This page covers migrating in and out of HubSpot CMS. SEO output and pricing live on their own pages.

What moves into HubSpot CMS, and can you leave?

HubSpot CMS migration configuration

HubSpot themes are local source you manage with the HubSpot CLI (hs), which is also how serverless functions are built and deployed (into a .functions directory). This is the portable, version-controllable half of a HubSpot CMS theme.

Theme workflow (HubSpot CLI)bash
npm install -g @hubspot/cli
hs init                       # authenticate to your HubSpot account
hs fetch <src> <dest>         # pull theme/templates down to local source
# ...edit HubL templates, modules, serverless functions locally...
hs upload <src> <dest>        # push changes back to HubSpot
# Serverless functions live in a .functions dir (serverless.json + .js + package.json).

At cutover, preserve SEO by uploading 301s in bulk via CSV (Settings, Content, Domains & URLs, URL Redirects). HubSpot supports permanent (301), temporary (302) and proxy (305) types, plus flexible pattern rules. Note redirects only work for domains hosted in HubSpot.

Bulk redirect map (CSV)text
# Bulk URL redirects CSV (Settings -> Content -> URL Redirects -> Import)
original_url,destination_url,redirect_style
/old-blog/hello-world,/blog/hello-world,301
/promo,/campaigns/spring,302
# Flexible rule: update URLs by structure, e.g. /old-blog/* -> /blog/*
# Redirects only work for domains connected to and hosted in HubSpot.

HubSpot's content export is broad for the static layer: HTML files for pages, posts and templates, plus page/post data, Files, HubDB, memberships, SEO data, the sitemap and URL redirects. The dynamic layer (HubL, serverless, forms, CTAs) does not run off-platform.

Export your content (the way out)text
# Settings -> Account Management -> Export your content & data
Portable (static layer):
  - HTML files for pages, posts, templates
  - page/post data, Files, HubDB, memberships, SEO data, sitemap, URL redirects (CSV)
NOT portable (proprietary, stops off-platform):
  - HubL templating, HubDB logic, serverless (NodeJS), smart content, forms, CTAs

What moves when you migrate to HubSpot CMS

Migration elementOn HubSpot CMSDetailSource
Theme (inbound)Rebuild from WordPressDedicated guide: recreate WordPress themes as HubSpot CMS themes; PHP/hooks become HubL
Side-by-side during migrationSubdomain coexistenceKeep the main site on WordPress while some content is hosted in HubSpot via a connected subdomain
Content export (outbound)BroadExport HTML files for pages, posts and templates, plus page/post data, Files, HubDB, memberships, SEO data, sitemap and URL redirects
Account-to-account mergeNot supportedNo merge between HubSpot accounts; export from one and import into the other
Serverless functionsNodeJS, Enterprise-onlyServer-side JavaScript on HubSpot's NodeJS runtime; Content Hub Enterprise; runs only inside HubSpot
Dynamic layer (outbound)Does not survive off-platformHubL, HubDB, serverless, memberships, smart content, forms and CTAs are proprietary and stop working once you leave

Source-to-HubSpot CMS mapping

WordPress elementLands on HubSpot asCaveatSource
index.php (entry template)base.htmlThe base HubSpot template that wires the head and standard includes
PHP / template tagsHubL filters, functions, tagsRe-author the templating logic in HubL
functions.phpHubL macros / serverless / custom appsNo direct equivalent; this is the heaviest part of the rebuild
wp_enqueue_style / _scriptrequire_css() / require_js()Map asset loading onto HubSpot's require helpers
Posts and pages (content)Imported contentImport content after the theme is rebuilt; not a theme-and-content one-click
Structured dataTemplate-level JSON-LDRe-authored in HubL templates; no native schema field

HubSpot CMS migration timeline and rollout

PhaseWhat happensEffortSource
1. Rebuild theme in HubLWordPress PHP/hooks become HubLHigh, functions.php has no equivalent
2. Coexist on a subdomainOptional side-by-side during the moveLow, connect a subdomain to HubSpot
3. Import contentPages and posts into HubSpotMedium, after the theme is ready
4. Map redirectsOld URLs to new, bulk CSVMedium, bulk-upload via CSV; flexible rules
5. Connect domain + SSLConnect domain; SSL auto-provisionsLow, SSL after connect (minutes to ~4h)

What to verify before you commit to HubSpot CMS

  • The static layer is portable but the dynamic layer is not: HubL templating, HubDB, serverless functions, memberships, smart content, forms and CTAs are proprietary and stop working once you leave, so anything dynamic is effectively one-way
  • Inbound is a theme rebuild, not an import: WordPress PHP and hooks become HubL and functions.php has no equivalent, so budget real development time rather than expecting a one-click migration
  • Serverless is Enterprise-only: server-side JavaScript runs on HubSpot's NodeJS runtime and requires Content Hub Enterprise, so any logic you build there raises both the plan tier and the lock-in
  • There is no account-to-account merge, so consolidating HubSpot portals means exporting from one and importing into the other rather than merging, plan multi-account moves around that

HubSpot CMS Migration FAQ

Can I import my WordPress site into HubSpot CMS?

Not as a one-click import. HubSpot documents recreating a WordPress theme as a HubSpot theme, which is a rebuild. PHP and template tags become HubL, wp_enqueue_style and wp_enqueue_script become require_css and require_js, and index.php becomes base.html. functions.php, which has no direct equivalent, becomes HubL macros, serverless functions or custom apps. After the theme is rebuilt you import your content. You can also run side-by-side on a subdomain during the migration.

Can I export my site out of HubSpot CMS?

The static layer, yes, and fairly broadly. HubSpot exports HTML files for pages, posts and templates, plus page and post data, Files, HubDB, memberships, SEO data, the sitemap and URL redirects. What does not come with you is the dynamic layer: HubL templating, HubDB logic, serverless functions, smart content, forms and CTAs are proprietary and stop working off-platform. Treat the HTML and theme source as portable and the dynamic features as one-way.

How bad is HubSpot CMS lock-in?

Medium-to-high, and it lives in the dynamic layer. Your theme source is local and version-controllable through the HubSpot CLI, and the content export is generous, so static pages move out cleanly. But anything dynamic, HubL templates, HubDB tables, serverless functions, memberships, smart content, forms and CTAs, only runs inside HubSpot and stops working once you leave. The more of your site depends on those, the more one-way the platform is.

Are HubSpot serverless functions portable?

No. Serverless functions execute server-side JavaScript on HubSpot's NodeJS runtime and require Content Hub Enterprise. They are built and deployed with the HubSpot CLI into a .functions directory, but they run only inside HubSpot. So any logic you put there is both a higher plan tier and a piece of lock-in. If portability matters, keep critical logic in an external service the site calls, rather than in HubSpot serverless.

Can I merge two HubSpot accounts?

No. HubSpot states there is no way to merge all the data between accounts. The supported path is to export your content and data from one account and import it into the other. So if you are consolidating portals after a reorg or acquisition, plan it as an export-then-import project. Account for the dynamic features that will not transfer, and rebuild those in the destination portal.

Sources & verification

Verified by ComparEdgeMethod: Vendor docs, official pages, and selected independent sources
SourceWhat was checkedLast checked
Hubspot CmsOfficial product pageJuly 10, 2026
Hubspot Account Management Export Your Content And DatAccount Management Export Your Content And DataJuly 10, 2026
Hubspot Domains And Urls Connect A Domain To HubspotDomains And Urls Connect A Domain To HubspotJuly 10, 2026
Hubspot Domains And Urls Create And Manage Url RedirecDomains And Urls Create And Manage Url RedirectsJuly 10, 2026
Hubspot Improve Existing Sites Convert Wordpress ThemeImprove Existing Sites Convert Wordpress Theme To Hubspot.mdJuly 10, 2026
Hubspot Serverless Functions Overview.MdServerless Functions Overview.mdJuly 10, 2026

Every fact on this HubSpot CMS page is tied to a named source and a verification date. Freshness-sensitive figures trace to the sources above; verify against the vendor before relying on them.