1. Knowledge base
  2. Clientside Universal Integration

How to set up Universal Client-Side Integration through Google Tag Manager

Follow the steps below to integrate ProfitMetrics Universal Integration through Google Tag Manager


  1. Import pre-build container template
  2. Create tags
  3. Create document.cookie variable

NOTE: You will need your Public ID, we recommend recording it from here in advance

Import templates

  1. Download these two templates:
    https://drive.google.com/file/d/1povlq7HvjomVZVlmrWWYHwICQT6kP66p/view?usp=drive_link

    https://drive.google.com/file/d/1ipqGD8ET0K-a-awB4gLSdSU7IrT_3Rc0/view?us p=drive_link
  2. Navigate to https://tagmanager.google.com to select your account and container
  3. Select the NON-server container
  4. Click "Templates"
  5. Beside 'Tag Templates' click "New"
  6. Click the menu with the three dots at the top right.

  7. Click "Import", and select the Purchase event template downloaded above.


  8. Click the checkbox to Agree to Terms of Service.
  9. Click "Save"

  10. Click the X to close the editor.

  11. Click "New"

  12. Click the menu with the three dots at the top right.

  13. Click "Import" and select the All Pages template downloaded above.

  14. Click the checkbox to agree to the Terms of Service.

  15. Click "Save"

  16. Click the X to close the Template Editor. 


Create tags


  1. Click "Tags"
    Set up tracking for your website using Google Tag Manager - Step 17

  2. Click "New"
    Set up tracking for your website using Google Tag Manager - Step 18

  3. Click the tag icon to choose a tag.
  4. Click "ProfitMetrics - Universal Integration - All Pages"

  5. Click the "1A2B3C4D5E6F7G8H" field.

  6. Paste the Public ID found in ProfitMetrics > Websites 

  7. Click the trigger icon to choose a trigger.

  8. Click "DOM Ready". You can also add any event that is specific to your Cookie Consent update.
    Screenshot 2024-06-19 at 9.34.04 AM

  9. Click "Save"


  10. Click "Save"


  11. Click "New"


  12. Click the tag icon to choose a tag.


  13. Click "ProfitMetrics - Universal Integration - Purchase"


  14. Click the "1A2B3C4D5E6F7G8H" field.


  15. Paste the Public ID found in ProfitMetrics > Websites

  16. Click > beside "Additional Fields".


  17. Use the Block icon to search for any variables from this section that can be specified. Any field that does not have a corresponding variable, please leave blank.
  18. Click the trigger icon to choose a trigger


  19. Select the Purchase event. If it isn't clear which event is correct, click the 'i' for more information, and identify which purchase trigger is already in use, and use that one. It will likely be a Custom Event like this:
    Google Tag Manager Workflow - Step 2 (2)

  20. Click "Save"


  21. Click "Save"


Create document.cookie variable

  1. Click on "Variables", then click "New"


  2. Click the block to select the variable type.



  3. Click "JavaScript Variable."


  4. Click the text box for Global Variable Name


  5. Type "document.cookie"

  6. Copy/Paste the name "document.cookie" from the Global Variable name to the variable name at the top left


  7. Click "Save"


Once those changes are completed, your basic setup should be complete!

Verify changes by publishing and waiting for an order, or by placing a test order in preview (knowledge base article pending)