App Tutorial

Install HubSpot Tracking Code on Any Website: A Step-by-Step Guide

author
Jason Gong
App automation expert
Apps used
HubSpot
LAST UPDATED
April 15, 2024
TL;DR

Adding the HubSpot tracking code to your website involves accessing your HubSpot account, navigating to 'Tracking & Analytics' settings, and copying the embed code to your website's footer or through Google Tag Manager. This process is crucial for monitoring website traffic and gathering analytics across platforms like WordPress, Shopify, and more.

Understanding how to properly install this code can significantly enhance your site's data collection and analytics capabilities.

Enhance your HubSpot workflows and ensure your data is always up-to-date by automating tasks with Bardeen.

How to Add HubSpot Tracking Code to Website

Adding the HubSpot tracking code to your website is essential for monitoring website traffic and gathering analytics. This guide will walk you through the process, covering various platforms including WordPress, Shopify, Drupal, Magento, Wix, Joomla, Squarespace, and the integration with Google Tag Manager.

While adding the HubSpot tracking code is crucial, automating your HubSpot workflows with Bardeen can further enhance efficiency and data management.

Install HubSpot Tracking Code

To install the HubSpot tracking code, first, access your HubSpot account and navigate to the settings icon in the main navigation bar. Depending on your subscription, locate the 'Tracking & Analytics' settings or 'Tracking Code' for accounts with only access to Marketing Starter or HubSpot’s free tools. In the 'Embed code' section, click 'Copy' or opt to email the code to your web developer.

'var _hsq = window._hsq = window._hsq || []; _hsq.push(['setContentType', 'CONTENT_TYPE']);'

Replace 'CONTENT_TYPE' with the specific content type to bucket data into HubSpot page types for external pages. This additional code helps in attributing credits to various content types like website pages, landing pages, listing pages, blog posts, and knowledge articles.

Add HubSpot Tracking Code to WordPress

For WordPress users, it is recommended to install the HubSpot All-in-One Marketing - Forms, Pop-ups, Live Chat WordPress plugin. This plugin automatically installs the HubSpot tracking code on your WordPress site. If you cannot install the plugin, manually insert the tracking code by navigating to Appearance > Editor in your WordPress dashboard and pasting the code in your theme's Footer.

HubSpot Tracking Code Google Tag Manager

To integrate HubSpot with Google Tag Manager, copy the HubSpot tracking code and log into your Google Tag Manager account. Create a new tag with the tag type set to Custom HTML Tag and paste the HubSpot tracking code. Set up a triggering rule for the tag to fire on all pages where the Google Tag Manager code is installed. Remember to publish your container and tags after setting up.

Additionally, you can integrate Google Tag Manager directly with HubSpot-hosted content by selecting the 'Integrate with Google Tag Manager' checkbox in the 'Integrations' tab under 'Website' > 'Pages' in your HubSpot settings. Enter your Google Tag Manager ID to complete the integration.

Following these steps will enable you to successfully add the HubSpot tracking code to your website, allowing you to monitor traffic and gather valuable analytics across various platforms.

Enhance your data management with Bardeen: Create HubSpot ticket, add a new row to a Coda table when a HubSpot contact is created, and sync LinkedIn social activity to HubSpot contact. Download Bardeen now.

Explore how to integrate HubSpot with Salesforce, integrate HubSpot with LinkedIn to enrich and speed up multi-channel outreach, and sync HubSpot and Slack for instant alerts.

Automate Your HubSpot Workflows with Bardeen

While adding the HubSpot tracking code to your website is a manual process crucial for gathering insightful analytics, automating your HubSpot workflows can further enhance your website's efficiency and data management capabilities. Utilizing Bardeen, you can automate various tasks related to HubSpot, saving time and ensuring your data is always up-to-date.

  1. Create HubSpot ticket: Automate the creation of HubSpot tickets directly from your website, ensuring customer issues are promptly addressed and tracked for an improved support experience.
  2. Add a new row to a Coda table, when HubSpot contact is created: Sync new HubSpot contacts to a Coda table automatically, keeping your CRM and project management tools aligned and up-to-date.
  3. Sync LinkedIn Social Activity to HubSpot Contact: Enrich your HubSpot CRM by automatically updating contact properties with their LinkedIn social activities, providing deeper insights for personalized engagement strategies.

By leveraging these automations, you can significantly enhance your HubSpot management and ensure your data works for you. Start simplifying your workflows today by downloading the Bardeen app.

related automations
No items found.

Other answers for HubSpot

40+ Buying Signal Examples and Their Impact

Learn key buying signals with over 40 examples to identify customer interest and boost your sales effectiveness.

Read more
Ultimate Lead Scoring Guide: All Your Questions Answered

Explore our comprehensive guide on lead scoring to prioritize and convert leads effectively in sales processes for 2024.

Read more
How to Qualify Leads: Essential Steps & Tips

Learn key steps to qualify leads effectively, boost conversions, and refine your sales process for better ROI.

Read more
Cold vs Warm Leads: Conversion Strategies Explained 2024

Explore key differences between cold and warm leads and learn top conversion strategies to optimize your sales funnel in 2024.

Read more
Add HubSpot Certification to LinkedIn: A Step-by-Step Guide

Learn how to manually add your HubSpot certification to LinkedIn by updating the Licenses & Certifications section, showcasing your achievements.

Read more
Log LinkedIn Messages in HubSpot: A Step-by-Step Guide

Learn how to log LinkedIn messages in HubSpot using third-party tools like Hublead for improved CRM efficiency and sales processes.

Read more
how does bardeen work?

Your proactive teammate — doing the busywork to save you time

Integrate your apps and websites

Use data and events in one app to automate another. Bardeen supports an increasing library of powerful integrations.

Perform tasks & actions

Bardeen completes tasks in apps and websites you use for work, so you don't have to - filling forms, sending messages, or even crafting detailed reports.

Combine it all to create workflows

Workflows are a series of actions triggered by you or a change in a connected app. They automate repetitive tasks you normally perform manually - saving you time.

get bardeen

Don't just connect your apps, automate them.

200,000+ users and counting use Bardeen to eliminate repetitive tasks

Effortless setup
AI powered workflows
Free to use
Reading time
Thank you! Your submission has been received!
Oops! Something went wrong while submitting the form.
By clicking “Accept”, you agree to the storing of cookies. View our Privacy Policy for more information.