Maintaining MonsterInsights connection info during a site copy

44 Views Asked by At

I have WordPress sites hosted in WP Engine and right now I am using MonsterInsights to connect to our Google Analytics (GA4). Only the Production site is connected and when I copy from Staging to Production, that obviously gets undone, so I have to reconnect MonsterInsights each time. Does anyone have a strategy for re-connecting after a site copy? I was thinking of saving settings from database in a script and running post-copy, but I don't know where in the db settings live. I could also have the staging site connected to GA, but don't want to "pollute" the data...any suggestions?

0

There are 0 best solutions below