I’ve been looking into customizing quotes using the new HubSpot CPQ model, but I can’t find clear information on how to do this at the code level.
In the official documentation, I’ve seen that you can create and edit templates through the UI, but I haven’t found a way to:
Edit a template directly in code (like we could with the legacy quotes).
Add custom modules inside a CPQ template.
Deploy/mount those modules into a new or existing template.
With legacy quotes, it was possible to work directly with the template code and extend it with modules. However, in the new CPQ model I don’t see an equivalent option, nor do I find clear documentation on this.
My specific questions are:
Is there currently a way to edit CPQ templates directly in code?
Is it possible to add custom modules to a CPQ template?
If yes, what’s the process for implementation? (e.g. using hs fetch / hs upload, or something else?)
Any reference, example, or guidance would be super helpful
Hey @CarlosAvilez - thanks for posting in the Community!
I understand that we’re looking for insight on how to customize quotes using the new HubSpot CPQ model, specifically at the coding-level. I’d like to tag in some experts here to see if they have any thoughts for us! @Kevin-C, @tjoyce, @SteveHTM - any answers to @CarlosAvilez’s questions?
Shane, Community Manager
I’m looking for a way to achieve this too. So far, I haven’t found any option for this leading me to believe that custom coded quote templates aren’t available for the new CPQ experience at this time. Subscribing to this thread in case anyone finds anything different however.
I’m looking for this too but it looks like it’s not possible at the moment. The new CPQ Quote theme is not available to access (located at @hubspot/cpq-theme/) and it doesn’t seem like the system is designed to load other files as quote templates yet.
The templateType for the CPQ Quotes still use “quote” like normal quotes so HubSpot must be hardcoding and/or limiting where it loads the templates. I can clone the CPQ quote template file but I get lots of errors/warnings with missing data and/or other files.
Yeah I got about as far as you did there. The modules aren’t accessible either so looks like we can only wait for the team to allow custom coded templates we create to be used in the new experience. I suspect it’ll be something similar to enabling drag and drop functionality amd other things given that seems like a key feature of the new CPQ experience.
For what it’s worth, the hubl.html structure reminds me of a CMS React project: CMS React quickstart - HubSpot docs
I was talking to my team about the quote templates and analyzing it in our test account and we thought it was going to be React based modules also!
Especially with the “live updates” that happen to OTHER modules when you do things like add/edit/delete Line Items. Aka, add Line Item, the summary module updates in real-time. Definitely feels like a useEffect happening.
Sharp eye! Glad the quoting tool is getting some love, quote templates have always been my favourite can’t wait to build templates when it becomes available for the AI-powered CPQ experience
For now, it’s a marked improvement from the default quote templates under the legacy quotes for those who didn’t have any developer resources available
Hey @CarlosAvilez,
sorry for re-opening this old topic.
Files and themes from the @hubspot and @marketplace folders are excluded from editing as they’re managed by HubSpot (or the theme provider).
To be able to modify them, you need to create a child-theme first by simply right-click on the desired theme and selct “create child theme”. Once done, copy the files you’d like to modify to the child-theme (right-click → Clone to child-theme).
After doing so, you can either modify the file(s) in the Design manager or fetch them to local environment with
hs cms fetch <hs-path> <local-path>
if you have several portals and the one you’re fetching it from is not the default one, you need to add --account=<HubID or portal-name> to the fetch query like this
I’m not even seeing the CPQ files. When I click on “view code in design manager” it will lead me to nothing. Also searching within the design manager I get nothing.
Hi @lindahouben, I hope that you are well!
To add to what @LevkaBrodersen shared (thank you!), this is actually the intended behavior for CPQ quotes.
Unlike legacy quotes, which allow custom coded templates in the design manager, CPQ quote templates use a standardized system and can’t be customized with code.
If you’re using CPQ quotes (available with Commerce Hub Professional or Enterprise), you might notice that the “View code in design manager” link doesn’t open editable files, since CPQ templates aren’t stored as code files there.
But you still have some great options! You can personalize and brand your CPQ quotes right in the UI by going to: Settings > Objects > Quotes > Quote templates.
If you require code-level customization, legacy quotes may be a better fit for your needs. These are available on Sales Hub accounts and allow for more advanced template editing.
I hope this helps!
Bérangère This post was created with the assistance of AI tools
But @BérangèreL if I understand correctly, the legacy quoting option is not available for new Hubs, is that right? For Hubs created before a specific date, if they have Sales Hub, we can work perfectly with the legacy quoting tool. It works really well. We’ve customised some really nice, complex quotes. For new Hubs, we need to use CPQ Quotes, right?
Hi @LevkaBrodersen and thanks for following up!
CPQ quote templates are designed to provide a streamlined and consistent experience. While they can’t be customized at the code level, they can be tailored through HubSpot’s UI using branding and template settings. At this time, CPQ templates don’t support HubL/HTML customization.
If you’re looking for full code-level flexibility, legacy quote templates offer that capability. They support custom HTML + HubL, CSS, JavaScript, and access to template_data variables.
However, as noted in the documentation, legacy quotes are only available to certain existing accounts. Newer accounts using Commerce Hub Professional or Enterprise use CPQ quotes instead.
With CPQ quotes, customization is focused on easy-to-manage UI-based branding and template settings. And if you’d like to create or manage CPQ quotes programmatically, the Quotes API endpoints are available for that.
While the template rendering itself isn’t code-customizable, you still have solid options for automation and quote management.
I hope this helps!
Bérangère This post was created with the assistance of AI tools
What @LevkaBrodersen mentioned is correct, you cannot use the Legacy Quotes anymore, ALL new accounts are only able to use the new CPQ tooling. So any custom code changes are not eligble anymore.
Maybe they will add this in the future.
@BérangèreL@lindahouben@LevkaBrodersen I’ve heard that HubSpot is working on introducing custom code modules for CPQ templates sometime in the future. Quotivity (my company) also has an advanced quoting solution that offers quote templates built using the standard Landing Page CMS drag-and-drop editor, making it easy to incorporate brand-aware designs into quote templates. And beyond that, Quotivity allows you to manage complex pricing, configurable products, and create sophisticated quote automations. We’d love to give you a demo if you’re interested.