Back to Help

Troubleshooting Guide

Solutions for common issues with the PMax script

Use Preview to Debug

Before reporting an issue, run the script using Preview (not Run) to see real-time logs. Copy the full log text (not a screenshot) when requesting support.

Setup Issues

SHEET_URL is empty or script can't access sheet

Cause: Sheet URL not added or permissions issue

Fix: Paste your sheet URL between single quotes on line 18. Ensure you own the sheet and it's accessible.

Script won't authorize or keeps asking for permissions

Cause: Authorization flow incomplete

Fix: Click 'Advanced' → 'Go to [Script name] (unsafe)' → Grant all permissions. May need to authorize twice.

No data appearing in sheet after run

Cause: No PMax campaigns or wrong date range

Fix: Verify account has active PMax campaigns with spend in last 30 days. Check execution logs for errors.

Data Issues

Numbers don't match Google Ads UI

Cause: Date range or timezone differences

Fix: Script uses last 30 days and account timezone. UI might show different range. Check for removed campaigns.

Search Terms tab is empty

Cause: No search term data available yet

Fix: Wait 24-48 hours after campaign launch for Google to provide search term data.

Products tab is empty

Cause: Not a Shopping/Product feed campaign

Fix: Products tab only works for Shopping or PMax campaigns with product feeds linked.

Execution Issues

Script times out / execution exceeded 5 minutes

Cause: Too much data to process

Fix: Reduce numberOfDays in Settings tab (try 14 days). Disable asset fatigue analysis (RUN_ASSET_FATIGUE_ANALYSIS = false).

Cannot read property 'getSheetByName' of null

Cause: Sheet URL incorrect or inaccessible

Fix: Verify SHEET_URL is correct and sheet hasn't been deleted. Check sheet permissions.

Script worked yesterday, broken today

Cause: Google API changes

Fix: Check members' area for updated script version. Post logs in Q&A if issue persists.

Still Need Help?

If your issue isn't covered here:

Check the FAQ for quick answers
Email support at mike@mikerhodes.com.au