GSC_PAGE_QUERIES
Get search queries driving traffic to a specific page.
=GSC_PAGE_QUERIES(pageUrl, startDate, endDate, [limit], [siteUrl])Returns: 2D array with columns: Query, Clicks, Impressions, CTR, Position
Overview
GSC_PAGE_QUERIES reveals exactly which search queries are driving traffic to any specific page on your website. By providing a page URL, date range, and optional parameters, you get a detailed breakdown of every keyword that triggered your page to appear in Google search results, along with the clicks, impressions, CTR, and average position for each query. This is one of the most actionable functions for content optimization because it shows you the real search intent behind each page.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
pageUrl | string | Yes | The full URL of the page to analyze (e.g., "https://example.com/blog/my-post"). |
startDate | string | Yes | Start date in "YYYY-MM-DD" format or relative format like "-30d" for 30 days ago. |
endDate | string | Yes | End date in "YYYY-MM-DD" format or relative format like "-1d" for yesterday. |
limit | number | No (100) | Maximum number of queries to return. Defaults to 100, max 25000. |
siteUrl | string | No | The site URL property from Search Console. If omitted, uses the default connected property. |
Examples
Queries for a blog post
See which search queries are sending traffic to a specific blog post over the last 30 days.
=GSC_PAGE_QUERIES("https://example.com/blog/seo-guide", "-30d", "-1d")Output
| Query | Clicks | Impressions | CTR | Position |
| seo guide 2025 | 340 | 5200 | 6.5% | 2.8 |
| seo best practices | 210 | 8900 | 2.4% | 7.3 |
| how to do seo | 180 | 6100 | 3.0% | 5.6 |
| search engine optimization guide | 95 | 3400 | 2.8% | 6.1 |
Queries for a product page
Get the top 50 queries driving traffic to a product page in the last week.
=GSC_PAGE_QUERIES("https://store.com/products/wireless-headphones", "-7d", "-1d", 50)Output
| Query | Clicks | Impressions | CTR | Position |
| wireless headphones | 120 | 3800 | 3.2% | 6.4 |
| best wireless headphones 2025 | 85 | 2100 | 4.0% | 4.2 |
| bluetooth headphones review | 62 | 1900 | 3.3% | 5.8 |
Homepage query analysis
Analyze the top 500 queries leading users to the homepage over the last 3 months to understand brand vs. non-brand traffic.
=GSC_PAGE_QUERIES("https://myapp.com/", "-90d", "-1d", 500)Output
| Query | Clicks | Impressions | CTR | Position |
| myapp | 8200 | 12000 | 68.3% | 1.0 |
| myapp.com | 3100 | 4500 | 68.9% | 1.0 |
| task management app | 450 | 18000 | 2.5% | 8.2 |
| best productivity tool | 280 | 15000 | 1.9% | 9.5 |
Dynamic page URL from cell reference
Use a cell reference for the page URL so you can quickly switch between pages without editing the formula. Place the URL in cell A2.
=GSC_PAGE_QUERIES(A2, "-30d", "-1d", 200)Output
| Query | Clicks | Impressions | CTR | Position |
| crm comparison | 520 | 9400 | 5.5% | 3.1 |
| best crm for small business | 380 | 7200 | 5.3% | 4.5 |
| crm software reviews | 290 | 6800 | 4.3% | 5.2 |
Queries for a URL-prefix property
Specify a URL-prefix property explicitly when your account has multiple properties.
=GSC_PAGE_QUERIES("https://blog.company.com/post/analytics", "-30d", "-1d", 100, "https://blog.company.com/")Output
| Query | Clicks | Impressions | CTR | Position |
| web analytics tutorial | 190 | 4200 | 4.5% | 3.8 |
| google analytics setup | 145 | 5100 | 2.8% | 6.2 |
| analytics for beginners | 110 | 3300 | 3.3% | 5.1 |
Use Cases
Content Refresh Prioritization
Content teams analyze page-level query data to determine which articles should be updated first, focusing on pages where the primary keyword has dropped in position or where new relevant queries have emerged.
Keyword Cannibalization Detection
SEO specialists run GSC_PAGE_QUERIES on multiple pages targeting similar topics to identify keyword cannibalization, where two or more pages compete for the same queries and dilute each other's ranking potential.
Product Page SEO Audit
E-commerce SEO teams audit product pages to verify that the intended target keywords are the ones actually driving traffic, and discover new long-tail product queries to add to titles and descriptions.
Landing Page Intent Matching
Product marketing teams analyze query data for key landing pages to ensure the page messaging aligns with the search intent of visitors, improving both SEO rankings and conversion rates.
Internal Linking Optimization
Publishers use page query data to build smarter internal linking strategies, connecting pages that share related queries and creating topic clusters that strengthen overall domain authority.
Pro Tips
Build a content audit template: list your top pages in column A, then use =GSC_PAGE_QUERIES(A2, "-30d", "-1d", 10) in adjacent cells to see each page's top keywords at a glance.
Look for queries with high impressions but positions 8-20: these are keywords on the edge of page 1 where small content improvements could yield significant traffic gains.
Compare the top query for each page against the page's H1 and title tag. If they don't match, updating the title to include the top query often improves CTR and rankings.
Use conditional formatting to highlight queries with CTR below 2% in the results, making it easy to spot opportunities for meta description improvements.
For content cluster planning, run GSC_PAGE_QUERIES on your pillar page and look for queries that deserve their own dedicated pages, then create those pages and link back to the pillar.
Content optimization begins with understanding what users are actually searching for when they land on your page. GSC_PAGE_QUERIES bridges the gap between your content and user intent by showing you the exact phrases Google associates with your page. You might discover that a blog post about "email marketing tips" is also ranking for "how to write subject lines" or "email open rates" -- queries you could better target with content updates or new dedicated pages.
This function is particularly powerful for on-page SEO audits. For each important page, pull its query data to verify that your target keyword is indeed the top query by clicks. If unexpected queries dominate, it signals a content-intent mismatch that needs addressing. You can also identify cannibalization issues by checking if multiple pages compete for the same queries. Use the limit parameter to see beyond the obvious top keywords and explore the long-tail queries that collectively may represent a significant portion of your traffic. Combined with GSC_TOP_PAGES, this function enables a complete page-by-page content audit workflow entirely within Google Sheets.
Common Errors
NO_DATA: No search data found for the specified pageCause: The page URL does not match any indexed page in Search Console, or the page had no impressions during the specified date range.
Fix: Verify the exact page URL by checking GSC_TOP_PAGES output or the Search Console interface. Ensure the URL includes the protocol (https://), correct path, and any trailing slashes. Try widening the date range to capture more data.
NOT_AUTHORIZED: Access to Search Console property deniedCause: Your connected Google account does not have access to the Search Console property that owns the specified page URL.
Fix: Check that the page URL belongs to a Search Console property you have access to. If the page is under a different property (e.g., a subdomain property), specify the correct siteUrl parameter.
INVALID_URL: Page URL must be a valid URLCause: The pageUrl parameter is not a properly formatted URL.
Fix: Ensure the URL starts with "https://" or "http://", includes the domain, and has the correct path. Do not include URL fragments (#section). If referencing a cell, make sure the cell contains a valid URL string.
Frequently Asked Questions
Yes, the pageUrl must match exactly as it appears in Search Console, including the protocol (https://), trailing slashes, and any query parameters. If unsure of the exact URL, first use GSC_TOP_PAGES to see how Google reports your page URLs, then copy the exact string.
No, GSC_PAGE_QUERIES requires an exact page URL. For filtering by URL patterns (like all pages under /blog/), use GSC_QUERY with a page filter using the "contains" operator instead.
This can happen due to the row limit. If a page ranks for thousands of queries and you only retrieve 100, the sum will be lower than the total. Increase the limit parameter to capture more queries. Additionally, anonymized queries (very rare searches) are not reported individually but are included in aggregate page totals.
Use a FILTER function on the results: =FILTER(GSC_PAGE_QUERIES(url, start, end, 1000), INDEX(GSC_PAGE_QUERIES(url, start, end, 1000),,5) > 10). This filters for queries where the average position is greater than 10, meaning your page typically appears on page 2 or beyond.
Yes, by running GSC_PAGE_QUERIES for different date ranges and comparing results. For a time-series view, use GSC_QUERY with both "query" and "date" dimensions and a page filter to see daily query performance for a specific page.
If the specified URL has no search data (either it does not exist, is not indexed, or had no impressions during the date range), the function returns an empty result with only the header row. Double-check the URL format and try a wider date range.
Search Console typically consolidates AMP and mobile data under the canonical URL. Use the canonical URL as the pageUrl parameter. If your site uses separate mobile URLs (m.example.com), those would be separate pages in Search Console and you would need to query them individually.
Related Functions
Start using GSC_PAGE_QUERIES today
Install Unlimited Sheets to get GSC_PAGE_QUERIES and 41 other powerful functions in Google Sheets.