There are three ways this can be completed:

The first option is adding it to the Site where Google Analytics is added.

 onMessage > Website > Site Name (Usually is Main Site or similar)

  1. Site Settings Tab on the top Right (has a Gear Icon)
User-added image
  1. Scroll Down to the Google Analytics section
User-added image
  1. Press Enter a few times
  2. Add the code
Note: We do not have a way to test any of these options within our Software, so if this does not work then there is another option you can try.

You can add a embed Widget to a Page with the code and test that page to see if that works. 
To add a Embed Widget to a Page navigate to:

  1. onMessage > Website > Site Name
  2. Select Pages and Menus
  3. Click the editing Wrench on the Page you want to add the code to
  4. Click Edit Page Content
  5. In widgets within the left hand column, drag the Embed Widget onto a portion of the page for the code to be embedded
  6. Click the Gear Icon and paste in your Hubspot Code into the Embed Code box (We suggest to leave the Header Text blank so this does not appear anywhere visually on your website)
  7. Click Save

You can also add the Code in the Master Layout, which will add the code to all the Pages using that Layout. 
To do this, navigate to:

  1. onMessage > Website > Site Name
  2. Select Master Layouts
  3. Click Into the Master Layout Name
  4. In widgets within the left hand column, drag the Embed Widget onto a portion of the page for the code to be embedded
  5. Click the Gear Icon and paste in your Hubspot Code into the Embed Code box (We suggest to leave the Header Text blank so this does not appear anywhere visually on your website)
  6. Click Save