Child Themes on HubSpot: Upgrading Website Without Disrupting Production

Published on 17 min read
Child themes on HubSpot

Summary

A child theme in HubSpot is a theme that extends a parent theme via the `extends` field in `theme.json`: files in the same path override those of the parent, and the rest is inherited, which allows for customization without losing updates to the original theme.

  • Marketplace themes and Elevate, HubSpot’s current default theme, cannot be cloned; a child theme is the official way to customize them.
  • Limits per subscription: 1 child theme on Starter and free plans, 5 on Professional, and 10 on Enterprise; there is no such thing as a “child of a child.”
  • Overwriting `fields.json` replaces the entire file without merging: to add a field, copy the complete `fields.json` from the parent and add the new one.
  • You can create a child theme in the Design Manager using the “Create child theme” option, or via the CLI with `hs cms fetch`, `hs cms upload`, and `hs cms watch`.
  • To avoid breaking production: Use Git as your main source, override as few files as possible, document the overrides in a README, and test outside of production before deploying.

Every HubSpot site reaches a point where the original theme no longer works as-is. A button color, a different header, an extra module on the homepage. And that’s when many teams make the most costly mistake in the Content Hub: they edit the theme directly, miss out on the developer’s updates, and end up maintaining a fork that no one has documented.

Child themes exist to prevent exactly that. You create a layer on top of the original theme, change only what you need, and continue to receive updates from the parent theme. This guide explains how the inheritance mechanism works, how to create a child theme via the interface and the CLI, what can and cannot be overridden, and how to set up a deployment workflow that doesn’t take the production site offline.

Short answer: A child theme is a theme that extends another theme (the parent) using the `extends` field in `theme.json`. Any file that doesn’t exist in the child theme is inherited from the parent; any file that exists in the same path overrides the parent’s file. Use a child theme whenever you need to customize a Marketplace theme, the default HubSpot theme, or a custom theme maintained by another team.

Part of the guide: HubSpot implementation: the guide and checklist

What is a child theme in HubSpot?

A child theme is a Content Hub theme whose `theme.json` file specifies a parent theme in the `extends` field. Based on this declaration, HubSpot resolves each theme file in two steps: it first searches the child theme, and if it doesn’t find the file there, it uses the parent’s version. Templates, modules, CSS, JavaScript, and the `fields.json` file itself all follow this rule.

The result is a lean theme. A typical child theme has just a handful of files: the ` theme.json ` with the ` extends` declaration, a ` child.css`, a ` child.js `, and one or two templates that you actually needed to modify. Everything else continues to come from the parent, even when the parent changes.

This is different from cloning. A clone copies the entire theme to a new folder and severs the link to the original. If the theme developer fixes an accessibility bug in the menu or adapts the theme to a platform change, the clone doesn’t know about it. The child theme does.

HubSpot allows child themes from three sources: HubSpot’s own default themes (the @hubspot folder), themes from the Template Marketplace (the @marketplace folder), and custom themes that you or your agency maintain. For the first two, using a child theme isn’t just recommended—it’s the only option: HubSpot blocks the cloning of themes purchased from the Marketplace and Elevate, the current default theme.

If you’re new to the Content Hub as a developer, our comprehensive Content Hub roadmap for developers shows where themes fit into the architecture.

How does inheritance work between a parent theme and a child theme?

Inheritance between parent and child themes in HubSpot follows the file’s relative path: if the child theme has the file in the same path, it takes precedence; if not, the parent’s version applies—without merging content—and the theme settings remain independent.

There’s only one rule, and it applies to any file: if the relative path is the same, the child theme takes precedence. If the parent theme has `templates/home.html` and the child theme also has `templates/home.html`, HubSpot renders the child theme’s version. If the child theme doesn’t have it, HubSpot renders the parent theme’s version. There is no content merge between the two files.

This has three practical consequences that are worth understanding before you begin.

1. The folder structure must mirror that of the parent. A file named css/main.css in the child theme will only override css/main.css in the parent theme. If you save it as styles/main.css, it simply won’t be used. In the 2021 documentation, HubSpot already warned: “Any theme files HubSpot doesn’t find in the child theme folders automatically revert to parent theme files.”

2. Overwriting `fields.json` is all or nothing. The theme’s fields file (colors, fonts, and spacing that appear in the theme settings) is not merged. If the child theme has a `fields.json ` with three fields, the theme will have three fields, and any parent templates that depended on the others will break. If you need to add a field, copy the entire ` fields.json ` from the parent and append the new one to the end.

3. Theme settings are independent. The child theme has its own theme settings values. Changing the primary color in the child theme does not affect the parent theme, and vice versa. This is what allows you to have one child theme for the corporate website and another for campaign landing pages, each with its own color palette, all based on the same codebase.

When the parent theme developer publishes an update on the Marketplace, HubSpot updates the @marketplace folder, and the child theme begins to inherit the new version of every file you haven’t overwritten. The files you’ve overwritten remain as they were. That’s why we recommend overwriting as little as possible: every file copied to the child theme is a file you’ll need to maintain manually from that point on.

How do you create a child theme in HubSpot?

A child theme in HubSpot can be created using the Design Manager by right-clicking the parent theme folder and selecting “Create child theme,” or via the CLI by downloading the theme.json file with `hs cms fetch`, adding the `extends` field, and uploading it with `hs cms upload`.

There are two approaches. Using the Design Manager, you can create the child theme and edit or override files directly in HubSpot. The CLI is best suited when the theme will be versioned in Git, integrated into a deployment workflow, or developed by more than one person.

Using Design Manager (without local code)

  1. Go to Content > Design Manager.
  2. Open the @marketplace folder (purchased themes) or @hubspot folder (default themes) and locate the parent theme.
  3. Right-click the theme folder and select Create child theme.
  4. Enter a name. Under "Advanced options," you can change the destination folder and the names of the CSS and JS files.
  5. Confirm.

HubSpot creates a folder with a ` theme.json ` file that already points to the parent in the `extends` field, an empty ` child.css ` and ` child.js ` files, and the templates that contain the ` standard_header_includes` variable, so that the child’s CSS and JS are loaded. Everything you write in ` child.css ` is applied after the parent’s CSS.

Via the CLI (for Git version control)

The workflow with the HubSpot CLI is more explicit and gives you full control over what goes into the child theme. Starting with CLI v8, CMS-related commands are in the `hs cms` namespace, and your local environment must use Node.js 20 or higher.

mkdir my-child-theme hs cms fetch "@marketplace/theme-name/theme.json" my-child-theme/theme.json

Open the downloaded theme.json file, change the label, and add the ` extends` field:

{   "label": "Insight Sales - Site 2026",   "extends": "@marketplace/theme-name",   ... }

To overwrite a file, target only that file while keeping the same relative path:

hs cms fetch "@marketplace/theme-name/templates/home.html" my-child-theme/templates/home.html

Edit and upload:

hs cms upload my-child-theme my-child-theme

During development, `hs cms watch my-child-theme my-child-theme ` automatically pushes every saved change. For HubSpot default themes, the ` extends ` uses the `@hubspot/` prefix, for example ` @hubspot/elevate`.

The ` fields.json ` file deserves special attention. By default, the child theme inherits the `fields.json ` file from the parent theme, so you don’t need to create or copy this file if you don’t plan to modify it. If you need to customize the theme’s fields, copy the entire `fields.json` file from the parent theme and make the changes in the child theme. From then on, this version will override the one in the parent theme.

What can and cannot be overridden in a child theme?

A HubSpot child theme can override CSS, JavaScript, templates, modules, sections, partials, and the entire `fields.json` file, always in the same path as the parent; it cannot have its own child theme or remove a file from the parent—it can only replace it.

Element

Can it be overridden?

How

Caution

CSS

Yes

child.css (adds) or a file in the same directory (replaces)

Prefer child.css for adjustments; only replace the file when you need to remove rules from the parent

JavaScript

Yes

child.js or a file in the same directory

Same logic as CSS

Templates (.html)

Yes

File in the same relative path

You are responsible for maintaining that template; updates to the parent do not affect it

Modules

Yes

Entire module folder in the same path

Copy the entire folder (module.html, fields.json, meta.json, CSS, JS)

The theme’sfields.json

Yes

Entire file

No merge; copy the parent's and add it

Theme settings (values)

Yes, natively

Theme settings in the editor

They’re already independent of the parent; no need to override anything

theme.json

Partial

You can override label, extends, and whatever else you want

This is the file that defines the child; required

Sections and partials

Yes

File in the same directory

Check the exact path in the parent before copying

Child of a child

No

 

HubSpot does not allow more than one level of inheritance

Remove a file from the parent

No

 

At most, you can override it with an empty file or a template that doesn’t include it

A practical tip: if your child theme is overriding more than a third of the parent’s templates, the child theme model no longer makes sense. At that point, the parent theme is no longer serving as a foundation, and it may be time to create your own theme. Our guide to custom modules on the Content Hub helps you decide what should become a module and what should stay in the template.

Child theme, clone, or edit the theme directly: which one should you choose?

A child theme is the default choice for customizing third-party or shared themes because it preserves updates to the parent; cloning is best for a theme that will diverge significantly from the original; and editing the original theme only makes sense when it’s yours, is on Git, and no one else depends on it.

Criteria

Child theme

Clone the theme

Edit the original theme

Receives updates from the developer

Yes, for files that haven't been overwritten

No

Yes, but they overwrite your edits

Works with Marketplace and Elevate themes

Yes

No (cloning blocked)

No (read-only)

Size of the code you maintain

Only what has changed

The entire theme

The entire theme

Risk of breaking production when updating

Low, if only a small amount was overwritten

None, because it doesn't update

High

Freedom to restructure

Medium

Total

Total

Limit per account

1, 5, or 10, depending on the plan

No specific limit

No limit

Best for

Customizing third-party or shared themes

A custom theme that will differ significantly from the original

A theme that’s 100% yours, maintained by your team

Editing the original theme only makes sense when the theme is yours, the code is in Git, and no one else depends on it. Cloning makes sense when you’re going to transform the theme to the point where the original becomes merely inspiration. In all other cases, use a child theme.

How can you evolve a live site without breaking anything?

Updating a website on HubSpot without breaking production requires a combination of a child theme and a process: use Git as the main source, override as few files as possible, document what was overridden, test outside of production, and retest the affected pages when the parent theme updates.

A child theme solves half the problem, which is not missing out on updates from the parent theme. The other half is the process. This is the workflow we use for the websites we maintain on the Content Hub.

1. If the child theme is versioned in Git, set the repository as the primary source of the code. Every change must go through a commit and review, avoiding parallel edits in Design Manager. If someone changes a file directly in HubSpot, a subsequent HS CMS upload can replace that version.

2. Overwrite as few files as possible. Need to change the header? Overwrite the header partial, not the entire base template. Need to change a style? Use ` child.css`. Every extra file in the child theme is a file that won’t receive updates.

3. Document what has been overridden and why. Include a README.md in the root of the child directory with a list of files and the reason for each one. When the parent theme is updated, this list serves as your testing checklist.

4. Test outside of production before deploying. For page redesigns, Content Hub Professional and Enterprise accounts can use Content Staging to create and validate versions before replacing published pages. To test new assets and code, use a CMS Developer Sandbox or, for Enterprise accounts, a standard sandbox. If you choose to use a second child theme for testing, also consider the limit on the number of child themes available on your plan.

5. Use HubSpot’s version history as a safety net, not as a strategy. Design Manager saves versions of each file and allows you to revert changes. It’s meant for quick rollbacks. It does not replace Git.

6. When the parent theme updates, test the pages that use the overridden files. The parent update may change a CSS class or a variable name that your overridden template still uses. Inherited files update automatically; yours do not.

If the site is also multilingual, take extra care: use a single child theme for all languages, with differences resolved in fields and content—never one child theme per language.

Why are child themes a RevOps decision, not just a development one?

Child themes are a RevOps decision because they place adjustments—such as the color of a CTA—in the theme settings, where marketing can make changes independently; they ensure continuity when agencies and developers change; and they allow you to launch campaign landing pages without touching the corporate website.

Because the website is the operation’s biggest conversion engine, and the theme determines how long it takes to change anything on it. A marketing team that has to open a support ticket just to change the color of a CTA is paying the price for a poorly structured theme. A well-designed child theme places these decisions in the theme settings—where the marketing team can make changes independently—and leaves only structural tasks to the developer.

The second point is continuity. Agencies come and go; developers leave. A website built on a Marketplace theme with a child theme and Git has a clear path for those who come later: the parent theme is documented by the author, the child theme lists what has been changed, and the history is in the repository. A website built on a theme that’s been edited directly in Design Manager for three years is a black box.

And the third is campaign speed. With two or three child themes based on the same parent, the team can launch a landing page with event branding in an afternoon, without touching the corporate website. It’s this kind of autonomy that makes the Content Hub effective as a lead-generation platform—and not just as a hosting service.

Frequently Asked Questions

What is a child theme in HubSpot?

It’s a theme that extends another theme using the `extends` field in `theme.json`. Files that exist in the child theme override those in the parent theme at the same path; files that don’t exist are inherited. It’s used to customize a theme without losing updates to the original.

How many child themes can I create?

It depends on your plan: 1 with the free tools and the Starter plan, 5 with the Professional plan, and 10 with the Enterprise plan. All of them can point to the same parent theme.

Can I create a child theme from a Marketplace theme?

Yes, and it’s the only way to customize these themes, since HubSpot blocks the cloning of themes purchased from the Marketplace and the Elevate theme. In Design Manager, right-click the theme inside the @marketplace folder and select “Create child theme.”

Can I create a child theme from another child theme?

No. Inheritance is limited to a single level. If you need variations, create multiple child themes pointing to the same parent.

Does the child theme receive updates from the parent theme?

Yes, for all files that you haven’t overwritten. The files you copied to the child theme remain as they are and become your responsibility.

How do I add a new field to the theme settings in a child theme?

Copy the entire `fields.json ` file from the parent theme to the child theme, placing it in the same directory, and add the field. The files are not merged: if the child theme has an incomplete `fields.json ` file, the missing fields will be removed from the theme.

Does a child theme affect the site’s speed?

Not significantly. File resolution occurs during page rendering, not in the browser. What adds weight is the CSS and JS you add to child.css and child.js, so the same best practices apply as with any theme.

Can you version a child theme in Git?

Yes, and it’s a best practice for teams working on local development. The child theme can be versioned in Git and synced with HubSpot using `hs cms upload ` for one-time uploads or `hs cms watch ` during development.

Ready to take your operation to the next level?

Insight Sales has been building and maintaining websites on the Content Hub for 13 years, with over 300 clients and 25 HubSpot certifications. If your website is stuck with a theme that no one can update, or if you want to set up child themes and a deployment workflow that your marketing team can manage, reach out to us. We’ll start by assessing your current theme—not by presenting a proposal.

Talk to a specialist

What's next for your revenue operation? Let's look at it together.

A quick conversation with an engineer. (Not a sales call.)

Tags

Brenda Linhares - Partner & CMO

About the author

From journalism to tech: a marketer who turns data into revenue. Co-founded two companies, certified HubSpot Partner, and fluent in three languages and results.

Free assessment

Is your CRM helping your team or slowing it down?

In a conversation with a specialist, we review how your CRM is set up and what it takes for the team to drop the side spreadsheets.