Solution to Google Home link error when using Cloudflare to expose HA

After spending hours trying to figure out why I wasn’t able to re-link my Home Assistant app to my Google Home, after looking at the error logs on Google Cloud Console, I figure the root cause was Cloudflare’s Bot Fight Mode, that I at some point turned on. This was sending a challenge after the authentication that was breaking the authentication flow.
Google is apparently recognized as a bot. After disabling the Bot Fight Mode, I was finally able to link Home Assistant and Google Assistant.

The more you know

4 Likes

I’ve been trying to troubleshoot this for almost 24 hours when my Assistant started giving errors around 7am yesterday. This was my issue too, thank you for posting. Almost did a full re-setup too!

1 Like

Thank you! This fixed my issue as well instantly.

Was on the same boat since last night… This helped me. Thank you!

1 Like

Same here,

  • turned off Bot Fight mode
  • re-linked account (via Google Home app)
  • told google to “sync my devices”
  • → All good now! Thanks folks!

Not sure why this started for me yesterday as well. I did not change anything in Cloudflare and it has been working without any issues. That being said bot fight was turned on. Not sure if it was by me or not but I know I didn’t change anything in Cloudflare yesterday. I tried re-creating the google link without success. Disabling bot fight restored google home link immediately and as a result saved my sanity and possibly my marriage. So thank you for posting and sharing with the rest of us. Really appreciate it.

heh :joy:

if anything makes it to a bot list, Google must be in that list.