PMax Channel Spend Breakdown: Scripts, BigQuery & GAQL Guide

Learn how to extract PMax channel spend breakdown across Shopping, Video, Search, and Display using Google Ads Scripts, BigQuery exports, and GAQL queries.

By AdTurbo Team · 2026-08-31

Performance Max (PMax) campaigns are designed to unify Google's entire ad inventory—Search, Shopping, Display, YouTube, Gmail, Discover, and Maps—into a single automated black box. While machine learning handles automated bid adjustments and creative assembly across placements, advertisers are left with a critical visibility problem: Google's native interface bundles total campaign spend without showing a clear dollar-for-dollar breakdown by placement channel.

If your PMax campaign spends $10,000 in a month, how much went to high-intent Shopping clicks versus low-intent Display network placements or YouTube short impressions?

In this technical guide, you will learn how to extract PMax channel spend breakdown data using three repeatable methods: custom Google Ads Scripts, BigQuery SQL data pipelines via Google Ads Data Transfer, and Google Ads Query Language (GAQL) queries. We will also examine how to interpret the mathematical "residual spend" to isolate Display, Video, and Search delivery.

---

The PMax Black Box: Why Channel-Level Breakdown Matters

When Performance Max launched, it replaced Smart Shopping and Local campaigns while absorbing substantial Search and Display impression share. Google's core value proposition was algorithmic efficiency: cross-channel attribution powered by Smart Bidding.

However, automated multi-channel allocation introduces severe diagnostic blind spots for performance marketers.

The Hidden Spend Dilemma

Unlike traditional Google Ads campaign types where each channel operates in dedicated silos with individual budget controls, Performance Max pools your budget. Without channel-level reporting, several negative scenarios occur undetected:

1. Display Network Waste: PMax may allocate 30% to 50% of your daily budget toward low-converting mobile app placements, click farms, or unintended Display network banner inventory.

2. Video Inventory Bloat: If you upload video assets (or allow Google to auto-generate them), PMax may allocate significant budget to YouTube Shorts or in-stream ads that drive high view counts but zero post-click purchase intent.

3. Brand Search Cannibalization: PMax frequently captures high-converting brand traffic, masking poor non-brand Shopping and Display performance behind inflated overall campaign ROAS.

To diagnose performance degradation or validate scaling decisions, you must extract exact cost, impression, and conversion figures segregated by inventory type.

What the Native Google Ads UI Shows vs. What It Hides

Google has gradually rolled out incremental reporting features—such as Asset Group performance indicators, placement reports (showing impressions only, without spend or conversions), and high-level Search Term categories. You can review our detailed walkthrough on the Search Terms report guide to understand standard Search visibility limits.

Despite these updates, the standard Google Ads UI still does not provide a simple column for: Spend: Shopping, Spend: Search, Spend: Display, and Spend: Video.

To see exact cost figures by channel, you must query Google's underlying database tables where product listing costs, text asset costs, and total campaign metrics are stored separately.

---

Understanding Channels Inside Performance Max

Before running scripts or writing SQL, you must understand how Google's database schema categorizes Performance Max data.

+-------------------------------------------------------------+

| PERFORMANCE MAX CAMPAIGN |

+-------------------------------------------------------------+

|

+-----------------------+-----------------------+

| |

v v

+---------------------------+ +---------------------------+

| SHOPPING INVENTORY | | ASSET GROUP INVENTORY |

| (Google Merchant Center) | | (Text, Images, Videos) |

+---------------------------+ +---------------------------+

| |

v +--- Search Network

Shopping Placements +--- Display Network

(Search Page Shopping Grid, +--- YouTube / Video

Shopping Tab) +--- Discover / Gmail

How PMax Allocates Budget Across Networks

PMax evaluates real-time auction signals to shift spend dynamically across five main buckets:

• Shopping Ads: Product listing ads driven by your Google Merchant Center product feed.

• Search Ads (Text): Dynamic Search and text ads generated from your headlines, descriptions, and URL expansion settings.

• Display Network: Responsive Display Ads served across the Google Display Network (GDN), mobile apps, and AdSense publisher websites.

• YouTube / Video: In-stream, bumper, and YouTube Shorts video ads served via uploaded YouTube video links or auto-rendered video assets.

• Discover & Gmail: Native visual ads appearing in Google Discover feeds, YouTube home feeds, and Gmail promotion tabs.

The Mathematical Splitting Logic

Google Ads does not expose a single field called channelname. Instead, developers isolate channel costs using mathematical subtraction across multiple API endpoints:

$\text{Total Campaign Spend} - \text{Shopping (Listing Group) Spend} = \text{Asset Group Network Spend}$

From the remaining Asset Group spend, you can query Search and Video specific endpoints to isolate remaining Display/Discover impressions and spend:

$\text{Asset Group Spend} - \text{Search Asset Spend} - \text{Video Asset Spend} = \text{Display, Discover \& Gmail Residual Spend}$

Let us look at how to automate this calculation using Google Ads Scripts.

---

Method 1: Using a Google Ads Script for Channel Breakdown

A Google Ads Script runs JavaScript directly inside your Google Ads account, queries the reporting API, processes the math, and logs the output directly to a Google Sheet.

How the PMax Spend by Channel Script Operates

The script queries two core views in Google Ads:

1. shoppingperformanceview: Captures all metrics (Cost, Impressions, Clicks, Conversions, Conversion Value) driven directly by Merchant Center Product IDs.

2. campaign: Captures aggregate campaign-level metrics.

By comparing the aggregate metrics against the shopping performance metrics for any specified date range, the script calculates the non-shopping spend (Search, Display, Video, and Discover).

Complete Copy-Paste Google Ads Script

Follow these steps to deploy the script:

1. In your Google Ads account, navigate to Tools and Settings Bulk Actions Scripts.

2. Click the blue + button to create a new script.

3. Paste the following JavaScript code into the editor:

javascript

/

• Performance Max Channel Spend Breakdown Script

• AdTurbo Technical Guide

/

function main() {

// 1. Define Date Range (e.g., 'LAST30DAYS', 'THISMONTH', 'LASTMONTH')

const DATERANGE = 'LAST30DAYS';

// 2. Query Campaign-Level Aggregates for PMax

const campaignQuery =

SELECT

campaign.id,

campaign.name,

metrics.costmicros,

metrics.impressions,

metrics.clicks,

metrics.conversions,

metrics.conversionsvalue

FROM campaign

WHERE campaign.advertisingchanneltype = 'PERFORMANCEMAX'

AND metrics.costmicros 0

AND segments.date DURING ${DATERANGE}

;

const campaignData = {};

const campaignReport = AdsApp.search(campaignQuery);

while (campaignReport.hasNext()) {

let row = campaignReport.next();

let cId = row.campaign.id;

campaignData[cId] = {

name: row.campaign.name,

totalCost: row.metrics.costMicros / 1000000,

totalImpressions: row.metrics.impressions,

totalClicks: row.metrics.clicks,

totalConversions: row.metrics.conversions,

totalConversionValue: row.metrics.conversionsValue,

shoppingCost: 0,

shoppingImpressions: 0,

shoppingClicks: 0,

shoppingConversions: 0,

shoppingConversionValue: 0

};

}

// 3. Query Shopping-Specific Performance for PMax

const shoppingQuery =

SELECT

campaign.id,

metrics.costmicros,

metrics.impressions,

metrics.clicks,

metrics.conversions,

metrics.conversionsvalue

FROM shoppingperformanceview

WHERE campaign.advertisingchanneltype = 'PERFORMANCEMAX'

AND metrics.costmicros 0

AND segments.date DURING ${DATERANGE}

;

const shoppingReport = AdsApp.search(shoppingQuery);

while (shoppingReport.hasNext()) {

let row = shoppingReport.next();

let cId = row.campaign.id;

if (campaignData[cId]) {

campaignData[cId].shoppingCost += (row.metrics.costMicros / 1000000);

campaignData[cId].shoppingImpressions += row.metrics.impressions;

campaignData[cId].shoppingClicks += row.metrics.clicks;

campaignData[cId].shoppingConversions += row.metrics.conversions;

campaignData[cId].shoppingConversionValue += row.metrics.conversionsValue;

}

}

// 4. Output Breakdown

Logger.log('--- PERFORMANCE MAX CHANNEL SPEND BREAKDOWN (' + DATERANGE + ') ---');

for (let cId in campaignData) {

let c = campaignData[cId];

let otherCost = c.totalCost - c.shoppingCost;

let shoppingCostPct = ((c.shoppingCost / c.totalCost) 100).toFixed(2);

let otherCostPct = ((otherCost / c.totalCost) 100).toFixed(2);

let shoppingRoas = c.shoppingCost 0 ? (c.shoppingConversionValue / c.shoppingCost).toFixed(2) : '0.00';

let otherConvVal = c.totalConversionValue - c.shoppingConversionValue;

let otherRoas = otherCost 0 ? (otherConvVal / otherCost).toFixed(2) : '0.00';

Logger.log('Campaign: ' + c.name);

Logger.log(' Total Spend:

+ c.totalCost.toFixed(2));

Logger.log(' Shopping Spend:

Google Verified Fully Automated

Get More Leads & Sales From Google Ads — On Autopilot

AdTurbo is your AI Google Ads agent, built by top Google Ads agency owners. AdTurbo works tirelessly in the background managing your Google Ads to get more leads and sales, while you focus on running your business.

Sign up with Google

7-day free trial. No contracts. Cancel anytime.

+ c.shoppingCost.toFixed(2) + ' (' + shoppingCostPct + '%) | ROAS: ' + shoppingRoas);

Logger.log(' Other (Display/Search/Video) Spend:

Google Verified Fully Automated

Get More Leads & Sales From Google Ads — On Autopilot

AdTurbo is your AI Google Ads agent, built by top Google Ads agency owners. AdTurbo works tirelessly in the background managing your Google Ads to get more leads and sales, while you focus on running your business.

Sign up with Google

7-day free trial. No contracts. Cancel anytime.

+ otherCost.toFixed(2) + ' (' + otherCostPct + '%) | ROAS: ' + otherRoas);

Logger.log('--------------------------------------------------');

}

}

How to Schedule and Output Data to Google Sheets

To store this data over time for trend analysis:

1. Authorize the script inside Google Ads by clicking Preview and granting OAuth access.

2. Create an empty Google Sheet, copy its URL, and add the SpreadsheetApp library to the script.

3. Set a schedule (e.g., Every Monday at 6:00 AM) to append new rows weekly.

If you want an ongoing automated analysis of your multi-channel performance without writing and maintaining custom scripts, you can utilize an end-to-end Google Ads automation platform like AdTurbo to monitor cross-network shifts.

---

Method 2: Extracting Channel Spend via BigQuery and Google Ads Data Transfer

For enterprise accounts or agencies managing dozens of clients, running Google Ads Scripts across accounts causes timeout errors. The robust enterprise solution is exporting raw Google Ads log data to Google BigQuery using the native Google Ads Data Transfer Service.

+-----------------------+ Daily Data Transfer +-----------------------+

| Google Ads Engine | ------------------------- | Google BigQuery |

| (PMax Raw Log Data) | | (Raw Tables Export) |

+-----------------------+ +-----------------------+

|

v

+-----------------------+ Visualized Reports +-----------------------+

| Looker Studio / BI | <------------------------- | Custom SQL Query |

| (Channel Dashboards) | | (Calculates Splits) |

+-----------------------+ +-----------------------+

Setting Up the BigQuery Data Transfer Service

1. In your Google Cloud Platform (GCP) Console, create a new project (e.g., agency-ads-warehouse).

2. Navigate to BigQuery Data Transfers.

3. Click + Create Transfer, select Google Ads as the source, enter your 10-digit Google Ads Customer ID (or MCC ID), and select your BigQuery target dataset.

4. Enable standard daily transfer updates.

SQL Query to Separate Shopping, Asset Group, and Network Spend

Once BigQuery ingests your data, query the padsCampaignStats and padsShoppingProductStats tables.

Here is the SQL query to extract the exact breakdown:

sql

WITH CampaignTotals AS (

SELECT

cs.DATADATE AS reportdate,

c.campaignid,

c.campaignname,

SUM(cs.metricscostmicros) / 1000000.0 AS totalcost,

SUM(cs.metricsimpressions) AS totalimpressions,

SUM(cs.metricsclicks) AS totalclicks,

SUM(cs.metricsconversions) AS totalconversions,

SUM(cs.metricsconversionsvalue) AS totalconvvalue

FROM agency-ads-warehouse.googleads.adsCampaignStats cs

JOIN agency-ads-warehouse.googleads.adsCampaign c

ON cs.campaignid = c.campaignid

WHERE c.campaignadvertisingchanneltype = 'PERFORMANCEMAX'

AND cs.DATADATE = DATESUB(CURRENTDATE(), INTERVAL 30 DAY)

GROUP BY 1, 2, 3

),

ShoppingTotals AS (

SELECT

sps.DATADATE AS reportdate,

sps.campaignid,

SUM(sps.metricscostmicros) / 1000000.0 AS shoppingcost,

SUM(sps.metricsimpressions) AS shoppingimpressions,

SUM(sps.metricsclicks) AS shoppingclicks,

SUM(sps.metricsconversions) AS shoppingconversions,

SUM(sps.metricsconversionsvalue) AS shoppingconvvalue

FROM agency-ads-warehouse.googleads.adsShoppingProductStats sps

WHERE sps.DATADATE = DATESUB(CURRENTDATE(), INTERVAL 30 DAY)

GROUP BY 1, 2

)

SELECT

ct.reportdate,

ct.campaignid,

ct.campaignname,

ct.totalcost,

COALESCE(st.shoppingcost, 0) AS shoppingcost,

ROUND((ct.totalcost - COALESCE(st.shoppingcost, 0)), 2) AS othernetworkscost,

ROUND((COALESCE(st.shoppingcost, 0) / NULLIF(ct.totalcost, 0)) 100, 2) AS shoppingspendsharepct,

ROUND(((ct.totalcost - COALESCE(st.shoppingcost, 0)) / NULLIF(ct.totalcost, 0)) 100, 2) AS otherspendsharepct,

ROUND(SAFEDIVIDE(st.shoppingconvvalue, st.shoppingcost), 2) AS shoppingroas,

ROUND(SAFEDIVIDE((ct.totalconvvalue - COALESCE(st.shoppingconvvalue, 0)), (ct.totalcost - COALESCE(st.shoppingcost, 0))), 2) AS otherroas

FROM CampaignTotals ct

LEFT JOIN ShoppingTotals st

ON ct.campaignid = st.campaignid

AND ct.reportdate = st.reportdate

ORDER BY ct.reportdate DESC, ct.totalcost DESC;

Connecting to Looker Studio for Visual Dashboards

Connect the SQL query view directly to Google Looker Studio:

1. In Looker Studio, click Create Data Source BigQuery Custom Query.

2. Paste your query.

3. Build a Stacked Area Chart showing reportdate on the X-axis, and shoppingcost vs othernetworkscost on the Y-axis.

4. Add a calculated scorecard metric for Shopping Share % and Non-Shopping ROAS.

---

Method 3: Querying the Google Ads API with GAQL

If you build internal tools or integrate with Python/Node.js pipelines, query the Google Ads API directly using GAQL (Google Ads Query Language).

Key GAQL Resources

To construct an accurate breakdown, query the following reporting resources:

• shoppingperformanceview: For Google Merchant Center product feed performance.

• assetgroupproductgroupview: For listing group performance segmented by asset group.

• campaignsearchterminsight: For aggregated search term clusters and intent breakdown.

• campaignplacementview: For non-owned Google Display Network, YouTube, and mobile app impression distributions.

Python GAQL Execution Example

Here is a Python snippet using the official google-ads client library:

python

from google.ads.googleads.client import GoogleAdsClient

def getpmaxspendbreakdown(client, customerid):

gaservice = client.getservice("GoogleAdsService")

Query Shopping Metrics

queryshopping = """

SELECT

campaign.id,

campaign.name,

metrics.costmicros,

metrics.conversions,

metrics.conversionsvalue

FROM shoppingperformanceview

WHERE campaign.advertisingchanneltype = 'PERFORMANCEMAX'

AND segments.date DURING LAST30DAYS

"""

responseshopping = gaservice.search(customerid=customerid, query=queryshopping)

shoppingmetrics = {}

for row in responseshopping:

cid = row.campaign.id

shoppingmetrics[cid] = {

"name": row.campaign.name,

"cost": row.metrics.costmicros / 1e6,

"conv": row.metrics.conversions,

"val": row.metrics.conversionsvalue

}

return shoppingmetrics

By executing this query alongside the campaign table, developers can calculate the exact split in programmatic pipelines.

---

Analyzing the Output: How to Read Shopping vs. Display vs. Video Spends

Once you extract your raw numbers, you will have two primary data buckets:

1. Shopping Spend: Product Listing Ads.

2. Non-Shopping (Residual) Spend: Search, Display, Video, Discover, and Gmail.

How do you determine what makes up the "Residual" spend?

The Math Behind Display and Video Spill

To isolate the components of the non-shopping residual spend, analyze your Asset Group Assets and Placement Impression Share:

+-------------------------------------------------------------+

| TOTAL PMAX CAMPAIGN SPEND |

+-------------------------------------------------------------+

|

+------------------------+------------------------+

| |

v v

+---------------------------+ +---------------------------+

| SHOPPING SPEND | | RESIDUAL / ASSET SPEND |

| (Directly Tracked) | | (Total - Shopping) |

+---------------------------+ +---------------------------+

|

+-------------------------+-------------------------+

| | |

v v v

+-------------------+ +-------------------+ +-------------------+

| SEARCH TEXT | | YOUTUBE/VIDEO | | DISPLAY/DISCOVER |

| (Search Insights) | | (Video Views) | | (Banner/Apps) |

+-------------------+ +-------------------+ +-------------------+

• Search Text Component: If you review the Search Terms Insights table, you can see search impression volume. If impressions correlate with high Click-Through Rates (4% to 10%), a significant portion of residual spend is Search Text.

• Video Component: If your campaign contains video assets and your placement report shows millions of impressions on YouTube channels with low CTR (<0.5%) and high view counts, residual spend is heavily allocated to YouTube.

• Display Component: If your placement report is dominated by anonymous.google, mobile apps (com.rovio..., com.game...), and low-tier AdSense domains with high impression volume and low conversion rates, your budget is bleeding into Display inventory.

Benchmarking Healthy Network Distributions

What should a healthy PMax distribution look like for ecommerce vs. lead generation? Use these industry baselines:

| Campaign Goal / Type | Target Shopping % | Target Search % | Target Display / Discover % | Target Video % |

| :--- | :--- | :--- | :--- | :--- |

| Ecommerce (Feed-Driven) | 70% – 85% | 10% – 15% | 5% – 10% | 0% – 5% |

| Ecommerce (Brand Growth) | 50% – 60% | 15% – 20% | 15% – 20% | 10% – 15% |

| Lead Gen (No Feed) | N/A (0%) | 60% – 80% | 10% – 20% | 10% – 20% |

| PMax Feed-Only (No Assets) | 98% – 100% | 0% – 2% | 0% | 0% |

If your ecommerce PMax campaign shows under 50% Shopping spend while ROAS is declining, your budget is being diverted into low-intent Display or Video auctions.

Comparison of Extraction Methods

| Extraction Method | Setup Complexity | Real-Time Latency | Historical Depth | Multi-Account Scalability |

| :--- | :--- | :--- | :--- | :--- |

| Google Ads Script | Low (Copy & Paste) | 1-2 Hours (Google API) | Up to Account Limit | Moderate (Needs MCC Script) |

| BigQuery Data Transfer | High (Cloud Setup) | 24 Hours (Daily Batch) | Unlimited (Data Retention) | Very High (Enterprise MCC) |

| Google Ads API (GAQL) | High (Dev Required) | Real-time / API Quota | Unlimited | Very High |

| AdTurbo Platform | None (Automated) | Continuous AI Sync | Full Account History | High (Instant Cross-Account) |

If you want an independent assessment of your account's waste across these placements, get a free Google Ads audit to identify leakage points instantly.

---

Actionable Optimizations Based on Channel Breakdown

Extracting the data is only the first step. What operational changes should you make when the data reveals inefficient channel allocation?

1. What to Do When Display/Video Cannibalizes 40%+ of Spend

If your script reveals that 40% or more of your budget is draining into Display and Video with poor conversion volume, implement these controls:

• Switch to a "Feed-Only" PMax Campaign: Create a Performance Max asset group with no text assets, no image assets, and no video assets—leave only the Google Merchant Center product feed connected. This forces PMax to run primarily across Google Shopping inventory and prevents Display and YouTube generation.

• Account-Level Placement Exclusions: Go to Tools and Settings Content Suitability Placement Exclusion Lists. Exclude all mobile app categories (Google Play and Apple App Store categories) to eliminate mobile game ad waste.

• Opt Out of Automatically Created Assets: In campaign settings, turn off Automatically Created Assets (both Text and Final URL expansion) to prevent Google from building ad hoc Display and Search combinations.

2. Controlling Brand Search Cannibalization

If non-shopping spend is high and conversions look inflated, PMax is likely bidding heavily on your own brand name. Review our guide on how to find negative keywords to identify brand query overlap.

• Apply Brand Lists as Negatives: Create a Brand List in Google Ads under Shared Library and attach it as a Brand Exclusion to your PMax campaign.

• Request Account-Level Negative Keywords: Contact Google Ads Support or use account-level negative keyword lists to prevent PMax from bidding on brand terms, reserving those for dedicated standard Search campaigns with exact match bids.

+-------------------------------------------------------------------------+

| PMAX CHANNEL OPTIMIZATION WORKFLOW |

+-------------------------------------------------------------------------+

|

v

/-------------------------------------------------\

/ Run Script / BigQuery Channel Spend Breakdown \

\-------------------------------------------------/

|

+----------------------------+----------------------------+

| |

v v

[ Shopping Spend 70% ], [ Non-Shopping 40% ]

| |

v v

Healthy Distribution Evaluate ROAS Split

• Scale target budget |

• Optimize asset quality v

+----------------+----------------+

| |

v v

[ Other ROAS High ], [ Other ROAS Low ]

| |

v v

Search Expansion Display/Video Waste

• Retain Assets - Go Feed-Only

• Add Brand Exclusions - Exclude Mobile Apps

• Remove Video Assets

3. When to Switch to Dedicated Search or Standard Shopping

If your extracted data reveals that PMax consistently misallocates budget away from top-performing products toward dead inventory, restructure your account architecture:

1. High-Value Product Segments: Move top-selling SKUs into a Standard Shopping Campaign with manual or Target ROAS bidding. Standard Shopping provides deterministic control over bid priority, negative keyword lists, and search term transparency.

2. High-Intent Search Queries: Isolate core commercial search themes into dedicated Search campaigns. For a complete structural review, reference our PPC audit checklist.

If you want an intelligent system to automate negative keywords, adjust bids, and balance your cross-network spend without manual scripts, explore modern PPC management software options tailored for multi-channel accounts.

---

Related Guides

• PPC Audit Checklist: 12 Steps to Fix a Leaking Google Ads Account

• How to Use the Google Ads Search Terms Report to Cut Wasted Spend

• How to Find Negative Keywords in Google Ads (Step by Step)

---

Frequently Asked Questions

What channels are included in Performance Max?

Performance Max serves ads across all of Google's core inventory channels: Google Search, Google Shopping, the Google Display Network (GDN), YouTube (In-stream, Shorts, and Feed), Discover, Gmail, and Google Maps. The campaign uses automated bidding to dynamically distribute budget across these placements based on your conversion goals.

How can I see Shopping vs. Display spend in PMax natively?

The native Google Ads UI does not provide a standard column splitting total spend into Shopping versus Display. However, you can see total Shopping metrics by navigating to the Products or Listing Groups tab inside the campaign, or by using custom Google Ads Scripts that subtract Listing Group cost from total Campaign cost.

How many PMax campaigns should I have in my account?

Most accounts perform best with 1 to 3 Performance Max campaigns categorized by product margin, ROAS targets, or distinct product categories. Fragmenting your budget across too many PMax campaigns dilutes conversion data, which slows down the machine learning bidding algorithm.

Does Performance Max use keywords?

Performance Max does not use traditional keyword bidding with match types like Standard Search campaigns. Instead, it uses Search Themes and audience signals as targeting guidelines, while automatically matching search queries using your landing page content, Merchant Center feed data, and uploaded text assets.

Google Verified Fully Automated

Get More Leads & Sales From Google Ads — On Autopilot

AdTurbo is your AI Google Ads agent, built by top Google Ads agency owners. AdTurbo works tirelessly in the background managing your Google Ads to get more leads and sales, while you focus on running your business.

Sign up with Google

7-day free trial. No contracts. Cancel anytime.