In October Google introduced a new version of Google Tag Manager's Preview and Debug mode, making it part of Google Tag Assistant at the same time. The new Preview mode is better in many ways, not least because it now appears in its own tab rather than in an iFrame on the page being debugged.
However if you have used it more than just a little bit, you will probably have already encountered this error:
That's right: you hit Preview in Google Tag Manager, enter your URL, and click Start. The blue connecting bar gets half way across the screen before grinding to a halt. And then, 20 seconds or so later, you get that frustrating 'Could not connect' timeout error.
There are lots of reasons this connection problem might happen. For example, the Tag Manager help community reported that it was sometimes a result of "Chrome putting background tabs to sleep" and that there was a fix in the works for that particular issue. Julius Fedorovicius at Analytics Mania has done a good job in rounding up many of the other reasons.
However if, like me, you use Brave as your browser of choice, the culprit is likely to be Brave's 'Shields' feature. Having 'Shields Up' on a website (which is the default) will absolutely prevent Tag Assistant from connecting. Incidentally having Shields Up will also block any other Google endpoints, including Google Ads, Google Analytics and Optimize.
I've been working on tagging implementations for a number of new sites recently, so this has caught me out more than once. I'm presuming the old Debugger also refused to work with Shields Up, so I'm not sure why it seems more tricksy now - perhaps because the Debugger itself and the site being debugged are in separate tabs?
Fortunately, the fix in this case is very simple: while viewing the site in question, click on Brave's 'Shield' icon (the lion face) in the toolbar and then click the toggle to bring 'Shields Down'.
If Tag Assistant is already showing the 'Could not connect' error, just toggling Shields Down might be enough to get it to connect. If not, then hit 'Retry' in the Tag Assistant tab.
After I first published this post, a couple of other analysts pointed out on Facebook that perhaps Brave - being a privacy-respecting browser that blocks third-party trackers by default - was perhaps not the right choice of browser for this particular job. Andrew Att said:
"I've found [Brave] extremely problematic for any kind of analytics, tracking, tagging etc. To be honest my advice would be to avoid it for this purpose."
I would tend to agree, but then swapping between different browsers for different tasks is also less than ideal.
And while I'm sure many people use Brave for the privacy it provides, that is not its only appealing feature. Personally I am more interested in its innovative ad model, which directly rewards users and enables them to reward publishers of their choice in turn (granted, that ad model would probably not be feasible without the privacy features).
Ideally, I'd like to be able to exempt Google Tag Manager from Brave's tracker and ad blocking globally (while continuing to block other so-called 'cross-site trackers'). However Brave doesn't currently allow exclusions like this in its 'global shield defaults' settings. So for now you will need to bring the Shields down on individual sites as and when you need to - or swap to a different browser when debugging.