Anyone found a solid fix for Google credentials (Sheets, Gmail, Drive) needing to be re-authorized often? Refresh tokens seem to drop, especially on workflows that don’t run constantly.
I’ve seen the suggestion to push the OAuth app to “In Production” in Google Cloud Console, has that solved it for you, or is there something else in the GCP setup that matters?
Also wondering if this behaves any differently between n8n Cloud and self-hosted on a VPS, or if it’s purely a Google side thing regardless of where n8n lives.
This is caused by your OAuth app being in ‘Testing’ mode in Google Cloud Console. Testing mode limits refresh tokens to 7 days — once they expire, you need to re-authenticate. The solution is exactly as mentioned: change your Google OAuth app from ‘Testing’ to ‘Production’ mode in Google Cloud Console. In Production mode, refresh tokens don’t have that 7-day expiration. The behavior is consistent whether you’re on n8n Cloud or self-hosted — it’s purely a Google OAuth configuration matter. Once you move to Production, you’ll also need to re-authenticate once more (your refresh token will be refreshed), and then it should remain valid for much longer. Make sure your app has completed the OAuth consent screen setup for Production mode before making the switch.