# Customising form embed code

**URL:** <https://community.hubspot.com/t/customising-form-embed-code/95041>\
**Category:** APIs & Integrations\
**Tags:** forms\
**Created:** [November 29, 2023, 3:22pm UTC](https://community.hubspot.com/t/customising-form-embed-code/95041 "2023-11-29T15:22:03Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![JBlake80](https://avatars.discourse-cdn.com/v4/letter/j/e5b9ba/32.png) [@JBlake80](https://community.hubspot.com/u/JBlake80)\
**Post date:** [November 29, 2023, 3:22pm UTC](https://community.hubspot.com/t/customising-form-embed-code/95041/1 "2023-11-29T15:22:03Z")

</div>

I am looking for a way to categorise my Hubspot forms. I have successfully set up tracking in GTM and while I can use URL or Form ID to include/exclude forms, I’m looking for something a little lower maintenance.

I noticed that the form ID is currently located in the embed script, however I am wondering if it would be possible to also add a form class?

If I were to manually type this in, would it work or would it prevent the form from loading?  
Does anyone have any other suggestions how to achieve this?Thanks in advance

---

<div class="post-metadata">

**Author:** ![Olivia\_Hatchi](https://avatars.discourse-cdn.com/v4/letter/o/74df32/32.png) [@Olivia\_Hatchi](https://community.hubspot.com/u/Olivia_Hatchi)\
**Post date:** [November 29, 2023, 4:42pm UTC](https://community.hubspot.com/t/customising-form-embed-code/95041/2 "2023-11-29T16:42:25Z")

</div>

@JBlake80 Hi Jake!  
Have you tested this out yet on a test website page? I think that might be the best way to answer this one.  
I’d llike to see if @Tom has any insight too?

---

<div class="post-metadata">

**Author:** ![JBlake80](https://avatars.discourse-cdn.com/v4/letter/j/e5b9ba/32.png) [@JBlake80](https://community.hubspot.com/u/JBlake80)\
**Post date:** [November 29, 2023, 4:55pm UTC](https://community.hubspot.com/t/customising-form-embed-code/95041/3 "2023-11-29T16:55:37Z")

</div>

I have tested it out and although the form works I can’t actually see any  
of the additional data that I have tried to put in.  
do you know how to assign a form class using the embed code?

---

<div class="post-metadata">

**Author:** ![Olivia\_Hatchi](https://avatars.discourse-cdn.com/v4/letter/o/74df32/32.png) [@Olivia\_Hatchi](https://community.hubspot.com/u/Olivia_Hatchi)\
**Post date:** [December 1, 2023, 6:01pm UTC](https://community.hubspot.com/t/customising-form-embed-code/95041/4 "2023-12-01T18:01:43Z")

</div>

@JBlake80 You can only customise the embed code of a form that has been [set as raw HTML](https://knowledge.hubspot.com/forms/how-can-i-share-a-hubspot-form-if-im-using-an-external-site#with-css-in-your-external-stylesheet-marketing-hub-professional-enterprise-or-legacy-marketing-hub-basic-only).The raw HTML code can then be plugged onto your site and you can add a css class to apply your own styling. This is the only way to add elements to the form code I am afriad. So if you want to add a class you will also nee dto apply your own styling to a raw form. [https://legacydocs.hubspot.com/docs/methods/forms/advanced\_form\_options](https://legacydocs.hubspot.com/docs/methods/forms/advanced_form_options)
