Troubleshooting OAuth
OAuth connects PerfoAds to your Google Ads accounts securely. When OAuth breaks, syncs fail and data stops updating. This guide helps you diagnose and fix OAuth issues including expired tokens, permission errors, missing accounts, and connection failures. Follow step-by-step solutions to restore Google Ads access.
What You'll Learn
- Understanding OAuth status indicators
- Diagnosing OAuth problems quickly
- Fixing expired or invalid tokens
- Resolving permission errors
- Troubleshooting missing accounts
- Reconnecting OAuth correctly
- Preventing future OAuth issues
- When OAuth auto-heals vs requires intervention
Time needed: 10 minutes to read
OAuth Quick Health Check
Check OAuth Status First:
- Go to Settings → Google Ads Connections
- Look for status indicator:
✅ Healthy:
Status: Connected
Token Valid: 45 days remaining
Last Refresh: 2 hours ago
⚠️ Warning:
Status: Connected
Token Valid: 3 days remaining (expiring soon)
Last Refresh: 15 days ago
❌ Critical:
Status: Disconnected
Token Valid: Expired
Last Refresh: Failed
[Screenshot: OAuth status showing healthy, warning, and critical states] Green = healthy, Yellow = needs attention soon, Red = broken now
What Is OAuth?
Simple Explanation: OAuth is how PerfoAds gets permission to read your Google Ads data without needing your password.
How It Works:
- You click "Connect Google Ads"
- Google asks: "Allow PerfoAds to access your Google Ads accounts?"
- You click "Allow"
- Google gives PerfoAds a special access token
- Token is valid for 60 days (Google auto-refreshes it)
Self-Healing: System automatically refreshes tokens before expiration. You usually don't need to do anything.
When It Breaks: Google account password changed, permissions revoked, or token expires unexpectedly.
Problem 1: OAuth Shows "Disconnected"
Symptoms
- OAuth status: ❌ Disconnected
- All syncs failing with "Invalid credentials" or "OAuth error"
- Red X icon next to Google Ads Connections
Cause 1: Token Expired
Diagnostic:
OAuth Status: Disconnected
Token Valid: Expired
Error: "Refresh token expired or revoked"
Why It Happens:
- Token reached 60-day limit without refresh
- Auto-refresh failed due to Google account change
- User revoked app permissions manually
Solution:
Step 1: Reconnect OAuth
- Go to Settings → Google Ads Connections
- Click Reconnect OAuth button
- You'll redirect to Google sign-in
Step 2: Choose Correct Google Account
- Use the Google account that has access to your Google Ads accounts
- If you manage multiple Google accounts, choose the right one
- Not sure? Check Google Ads → Settings → Account Access
Step 3: Grant Permissions
- Google shows: "PerfoAds wants to access your Google Ads"
- Review permissions (read-only access to campaigns, keywords, metrics)
- Click Allow
Step 4: Verify Connection
- Redirects back to PerfoAds
- OAuth Status should now show: ✅ Connected
- Click Refresh Discovery to find accounts
Step 5: Test
- Go to Client List
- Pick a client
- Actions → Sync Now
- Sync should complete successfully
Expected Timeline: 2-3 minutes total
Cause 2: Google Account Password Changed
Diagnostic:
OAuth Status: Disconnected
Recent Event: Changed Google password last week
Why It Happens: Google security policy revokes OAuth tokens when password changes
Solution: Same as Cause 1 (Reconnect OAuth)
Prevention: After changing Google password, immediately reconnect OAuth in PerfoAds
Cause 3: App Permissions Revoked
Diagnostic:
OAuth Status: Disconnected
User manually removed PerfoAds from Google account permissions
Where This Happens: Google Account → Security → Third-party apps → PerfoAds → Remove Access
Solution: Reconnect OAuth (same steps as Cause 1)
Prevention: Don't revoke app access in Google unless you no longer use PerfoAds
Problem 2: OAuth Connected But Accounts Missing
Symptoms
- OAuth status: ✅ Connected
- Syncs work for some clients
- Other Google Ads accounts not showing in dropdown when adding client
Cause 1: Stale Discovery Cache
Explanation: Discovery cache lists available accounts. Cached for 24 hours.
Scenario:
Yesterday: Had access to 5 Google Ads accounts
Today: Gained access to 6th account
Dropdown: Still only shows 5 accounts
Solution:
- Go to Settings → Google Ads Connections
- Click Refresh Discovery button
- Wait 5-10 seconds
- Discovery runs and finds all accounts you have access to
- Go to Add Client dropdown
- New account should now appear
When to Refresh Discovery:
- After gaining access to new Google Ads account
- After OAuth reconnection
- If account list looks outdated
Cause 2: Missing Account Access
Diagnostic:
Account expected but not showing after Discovery refresh
Check Google Ads Access:
- Log into Google Ads: https://ads.google.com
- Click account switcher (top left)
- Can you see the missing account?
If Yes (you see it):
- Refresh Discovery in PerfoAds
- Should appear now
If No (you don't see it):
- You don't have access
- Contact account owner to grant access
- Account owner: Google Ads → Settings → Account Access → Add User
Access Level Required: Standard or Admin (read-only insufficient for sync)
Cause 3: Wrong Google Account Used for OAuth
Scenario:
Google Ads Account A: Managed by google-user-1@company.com
Google Ads Account B: Managed by google-user-2@company.com
OAuth Connected With: google-user-1@company.com
Result:
- Account A visible ✅
- Account B missing ❌
Solution:
Option 1: Reconnect OAuth with Correct Account
- Disconnect OAuth
- Reconnect
- Choose google-user-2@company.com
- Now Account B visible
Option 2: Grant Access to Other Google Account (recommended)
- Log into Google Ads Account B
- Settings → Account Access
- Add google-user-1@company.com as Standard or Admin
- Now both accounts visible with one OAuth connection
Problem 3: Permission Denied Errors
Symptoms
- OAuth: ✅ Connected
- Sync fails with "Permission denied" or "Insufficient permissions"
- Account appears in dropdown but sync doesn't work
Cause: Read-Only Access
Google Ads Access Levels:
- Admin: Full access
- Standard: Can view and edit (what PerfoAds needs)
- Read-only: Can only view (insufficient)
Diagnostic:
Sync Error: "Permission denied for customer XXX-XXX-XXXX"
Access Level: Read-only
Solution:
- Contact Google Ads account owner
- Request upgrade from Read-only to Standard access
- Account owner:
- Google Ads → Settings → Account Access
- Find your email
- Change access level to Standard
- Save
- In PerfoAds:
- Wait 5 minutes for Google to propagate change
- Retry sync
- Should work now
Why Standard Required: PerfoAds needs Standard to access full performance data and metrics
Problem 4: Token Expiring Soon Warning
Symptoms
- OAuth status: ⚠️ Connected (warning)
- Message: "Token expires in X days"
- X < 7 days
This is Normal (Self-Healing)
What It Means: System will auto-refresh token before expiration
Your Action Required: None (usually)
How Self-Healing Works:
Day 0: Token valid for 60 days
Day 53: System detects 7 days remaining
Day 54: System auto-refreshes token
Day 54: New token valid for 60 more days
When to Act
If Warning Persists >3 Days:
Day 1: Warning "7 days remaining"
Day 4: Still shows "4 days remaining" (auto-refresh hasn't happened)
Manual Refresh:
- Settings → Google Ads Connections
- Click Reconnect OAuth (pre-emptive refresh)
- Complete OAuth flow
- Token renewed for 60 days
Why Manual: Auto-refresh occasionally fails. Better safe than sorry.
Problem 5: OAuth Works But Sync Still Fails
Symptoms
- OAuth: ✅ Connected
- Token: Valid
- Discovery: Accounts found
- Sync: Still failing with errors
Possible Causes
Not an OAuth Issue:
- Customer ID incorrect → Fix: Update Customer ID in Client Settings
- Google Ads account suspended → Fix: Resolve suspension with Google
- Rate limiting → Fix: Wait and retry
- Network issues → Fix: Check internet connection
See: Troubleshooting Sync Issues for non-OAuth sync problems
Reconnecting OAuth: Best Practices
Step-by-Step Guide
Step 1: Prepare
- Know which Google account has access to your Google Ads accounts
- Have that Google account's password ready
- Close other Google account sessions (avoid wrong account selection)
Step 2: Disconnect Old OAuth (optional but recommended)
- Settings → Google Ads Connections
- Click Disconnect button
- Confirm disconnection
Step 3: Reconnect OAuth
- Click Connect Google Ads button
- Select Google account (choose carefully!)
- Google asks for permissions
- Review permissions (should be read-only access)
- Click Allow
Step 4: Verify
- Redirects to PerfoAds
- Check OAuth status: ✅ Connected
- Check token valid: "60 days" or similar
Step 5: Refresh Discovery
- Click Refresh Discovery
- Wait for completion
- Accounts list populates
Step 6: Test Sync
- Go to Client List
- Select a client
- Actions → Sync Now
- Verify sync completes successfully
Total Time: 3-5 minutes
[Screenshot: OAuth reconnection flow from start to finish] Follow these steps for successful OAuth reconnection
Understanding OAuth Scopes
What Permissions Does PerfoAds Need?
Required Scopes (Google's terminology):
https://www.googleapis.com/auth/adwords
- Read access to Google Ads data
- Required for syncing campaigns, keywords, performance
What PerfoAds Does NOT Have:
- Cannot modify campaigns
- Cannot change bids
- Cannot pause/enable ads
- Cannot create campaigns
- Cannot access billing info
- Cannot access other Google services (Gmail, Drive, etc.)
Read-Only Access: PerfoAds can only read data, never modify your Google Ads account
Preventing OAuth Issues
Best Practices
1. Don't Change Google Password Without Updating OAuth
Bad: Change Google password → Forget to reconnect OAuth → OAuth breaks 3 days later
Good: Change Google password → Immediately reconnect OAuth in PerfoAds
2. Monitor OAuth Health Monthly
Monthly Checklist:
- Settings → Google Ads Connections
- Check OAuth status: Should be ✅ Connected
- Check token expiration: Should show 30+ days
- If <30 days: System should auto-refresh soon, monitor
3. Don't Revoke App Access in Google
Google Account → Security → Third-party apps → PerfoAds
Do Not Click: "Remove Access" (unless you're done using PerfoAds)
4. Use Dedicated Google Account for Automation
Personal Account: john.personal@gmail.com
Business Account: john@agency.com (use this for OAuth)
Why: Business account less likely to change, more stable
When OAuth Auto-Heals
Self-Healing Scenarios
Auto-Fixed (no action required):
- Token approaching expiration (refreshes at 7 days remaining)
- Temporary Google API issues (retries automatically)
- Network blips during token refresh (retries)
Your Intervention Required:
- Token already expired (must reconnect)
- Google password changed (must reconnect)
- App permissions revoked (must reconnect)
- Wrong Google account used (must reconnect with correct account)
How to Tell: If OAuth status shows ❌ Disconnected, you must act. If ⚠️ Warning, system likely handling it.
Error Messages Decoded
"Invalid grant"
Meaning: Refresh token no longer valid
Fix: Reconnect OAuth
Common Cause: Google password changed or token expired
"Access denied"
Meaning: User declined OAuth permissions or insufficient access level
Fix:
- Reconnect OAuth and click "Allow" this time
- OR request Standard access level for account
"Redirect URI mismatch"
Meaning: OAuth callback URL doesn't match registered URL (rare)
Fix: Contact support (this is a configuration issue on PerfoAds's side)
"Invalid client"
Meaning: PerfoAds's Google OAuth credentials invalid (extremely rare)
Fix: Contact support immediately (system-wide OAuth issue)
Advanced Troubleshooting
Check Google Account Permissions
View Apps with Access:
- Go to: https://myaccount.google.com/permissions
- Find "PerfoAds" in list
- Check:
- Access granted? (should be)
- Permissions: "See your Google Ads data"
- Last accessed: Should be recent
If Not Listed: OAuth not connected, reconnect
If Listed But Sync Failing: Remove access, then reconnect OAuth fresh
Browser Console Errors
For Advanced Users:
- Open browser console: F12
- Go to Console tab
- Click "Connect Google Ads"
- Watch for errors during OAuth flow
- Common errors:
- Popup blocked: Allow popups for this site
- Cookies disabled: Enable cookies
- CORS error: Contact support
Common Questions
Q: How often do I need to reconnect OAuth? A: Almost never. System auto-refreshes tokens. Only reconnect if status shows ❌ Disconnected.
Q: Can I use multiple Google accounts for OAuth? A: Only one OAuth connection at a time. Choose account with access to most Google Ads accounts.
Q: What if I don't see "Allow" button during OAuth? A: Google may show "Cancel" only if app already has access. Check Settings → Google Ads Connections for status.
Q: Does reconnecting OAuth affect existing clients? A: No. Clients remain, data preserved. Only connection refreshes.
Q: Can I revoke OAuth access temporarily? A: Yes, but all syncs will fail until reconnected. Not recommended unless you're stopping use of PerfoAds.
Q: What data does PerfoAds store? A: Only the OAuth token (securely encrypted) and your Google Ads data after sync. PerfoAds never stores your Google password.
When to Contact Support
Contact Support If:
- Reconnected OAuth 3+ times but still shows Disconnected
- "Invalid client" error (system-wide OAuth issue)
- Accounts not appearing after multiple Discovery refreshes and verified access
- OAuth flow broken (redirects fail, errors during authorization)
- Token won't refresh despite being <7 days from expiration
Provide to Support:
- Screenshot of OAuth status
- Error message (exact text)
- Steps you've tried
- Google account email (used for OAuth)
Next Steps
Fix Google Ads connection issues with these guides:
- Troubleshooting Sync Issues - Fix sync problems after OAuth working
- Smart Sync Explained - How sync works with OAuth
- Global Settings - Configure OAuth and connections
- Adding First Client - OAuth setup during client onboarding
Monitor OAuth monthly to catch issues before they break
Reconnect immediately after changing Google password
Use stable Google account for business automation
Last Updated: October 4, 2025