Skip to content
Home » Blog » How do I edit the .js file for BigCommerce’s GA4 integration?

How do I edit the .js file for BigCommerce’s GA4 integration?

To edit the .js file for BigCommerce’s GA4 integration, you’ll need to follow these steps:

  1. Log in to your BigCommerce store’s control panel.
  2. Click on “Advanced Settings” in the left-hand menu, then select “Analytics” from the dropdown menu.
  3. Scroll down to the “Google Analytics” section and click on the “Set Up” button.
  4. In the “Google Analytics Set Up” window, click on the “Use the Global Site Tag (gtag.js)” option to enable GA4.
  5. Under the “Add Additional Code Snippets” section, click on the “Edit” button next to the “gtag.js Configuration” option.
  6. This will open up the “Google Analytics Configuration” modal window. Here, you can add or edit your GA4 tracking code.
  7. Once you’ve made your changes, click on the “Save” button to save your changes.

Note that editing the GA4 tracking code may require some knowledge of JavaScript and the GA4 tracking API. If you’re not comfortable making these changes on your own, you may want to consult with a developer or seek support from BigCommerce or Google Analytics.