# Hubspot tracking code and MadCap

**URL:** <https://community.hubspot.com/t/hubspot-tracking-code-and-madcap/107033>\
**Category:** APIs & Integrations\
**Tags:** professional\
**Created:** [May 13, 2024, 4:56pm UTC](https://community.hubspot.com/t/hubspot-tracking-code-and-madcap/107033 "2024-05-13T16:56:31Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![MRusso9](https://avatars.discourse-cdn.com/v4/letter/m/f6c823/32.png) [@MRusso9](https://community.hubspot.com/u/MRusso9)\
**Post date:** [May 13, 2024, 4:56pm UTC](https://community.hubspot.com/t/hubspot-tracking-code-and-madcap/107033/1 "2024-05-13T16:56:31Z")

</div>

We are having challenges dropping Hubspot tracking code onto MadCap, our authoring tool for our technical docs site. I’m ommitting our actual hubspot-id in the code below using “hubspot-id”.

**\<script type=“text/javascript” id=“hs-script-loader” async=“async” defer=“defer” src="file://js.hs-scripts.com/hubspot-id.js\>**

MadCap does not accep the above code, where ‘defer’ is an unexpected token, so we modified it to the following:

**\<script type=“text/javascript” id=“hs-script-loader” async defer src="file://js.hs-scripts.com/hubspot-id.js\>**

However, when we do that Hubspot does not pick u on it, showing the status as blocked.

Has anyone had success modifying the Hubspot tracking code to work with MadCap? Thank you!

---

<div class="post-metadata">

**Author:** ![Jaycee\_Lewis](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/jaycee_lewis/32/61352_2.png) [@Jaycee\_Lewis](https://community.hubspot.com/u/Jaycee_Lewis)\
**Post date:** [May 14, 2024, 5:56pm UTC](https://community.hubspot.com/t/hubspot-tracking-code-and-madcap/107033/2 "2024-05-14T17:56:52Z")

</div>

Hey, @MRusso9 👋 This is a tough one to find any related community posts for. I found this older post in the MadCap community that gives a clue, but my not the full needed info [HubSpot - MadCap Software Forums](https://forums.madcapsoftware.com/viewtopic.php?p=137943) We’ll leave this open in-case other community members have any suggestions.

Best,

Jaycee
