Docs
Paid Ads and Analytics
Google Tag Manager

Google Tag Manager

Google Tag Manager (GTM) simplifies the management of marketing and analytics tags on your website. It eliminates the need to manually update code on your site; you can manage and deploy tags directly from the GTM interface. This guide walks you through the setup process.

Steps to Set Up GTM

  1. Login to GTM and Create an Account

    GTM Account Creation
    • Enter an account name, container name, and select "Web" as the target platform.
    GTM Platform Selection
    • Click the "Create" button to set up the account.
  2. Add the GTM ID to Your Project

    • Once the account is created, you'll receive a GTM ID (e.g., GTM-XXXXXXX). Copy this ID.
    GTM ID
    • Open the /settings.js file located in the root directory of your project. This is the central configuration file for your StartupBolt application, containing various settings that control different aspects of your web app.
    • Paste the GTM ID as the value for googleTagManagerId under the MARKETING object.
    Adding GTM ID in settings.js
  3. Preview and Test GTM Setup

    • Ensure your website is running locally by typing npm run dev in your terminal. The site should be accessible at http://localhost:3000. If port 3000 is unavailable, it might use another port like 3001, 3002, etc.
    • Next, go to the GTM dashboard and click on the "Preview" button.
    GTM Preview Mode
    • Enter your local website URL (e.g., http://localhost:3000) and click "Connect."
    Connecting GTM to Local URL
    • If everything is set up correctly, the Tag Assistant will indicate that it is connected. This confirms that GTM is properly integrated.
    Tag Assistant Connection Confirmation

Now, let's proceed to set up analytics so you can monitor and visualize your website's performance effectively.