The WP Google Analytics Events plugin supports Google Analytics 4 through Global Site Tags.
How to set up tracking for Google Analytics 4
If you already added the code snippet directly to the theme or via a third-party plugin, set the Snippet type to add to “None”. That’s it. Our plugin should detect the code snippet and use it for sending out events.
If you want to use the WP Google Analytics Events plugin for adding the code snippet:
- In the Google Analytics admin settings, look for the MEASUREMENT ID. It should be under “Data Streams” and then click the Web then the data stream. If you don’t see one, you can click the add stream button. Here is how it should look:
2. Once you grab the measurement id, head over to the plugin settings and set it in the Google Analytics Tracking ID.
3. Set the Snippet type to add to Global Site Tag and save.
The end result should look similar to this: