For WordPress with Woo-commerce installed
- Install GTM4WP
- Setup a Google Analytics and get a measurement ID, starts with G-
- Setup a G Tag Manager Account and follow this guide.
- If you publish the tag, and you get an error: Unknown variable “Event” found in a tag.
- You will need to enable the Event system variable first. It can be done by visiting the “Variables” page, select “Configure” in the “Built-In Variables” panel and check the box next to the “Event” variable.
- In GTM4WP you will need to have the following settings
- Google Tag Manager ID: starting with GTM-
- Container code ON/OFF: Turned to On
- Container code compatibility mode: Manually coded (needs tweak in your template)
That should be all the settings for GA4.
Default WordPress Sitemap location
For WordPress no SEO plugins installed
However I do not recommend that you submit this to google console but you submit the relevant inner sitemaps instead EG
- For Pages
- For posts
- For products
- Otherwise it will also add
Those additional sitemaps will probably not be needed for google search console.
Which will probably submit duplicate content.