SE Ranking to Google Sheets, track AI SERP mentions
You can’t manage what you can’t see. And right now, most teams have almost zero visibility into how AI search engines talk about your brand, even when you “rank” just fine in traditional SEO tools.
SEO strategists feel it first when leadership asks, “Are we showing up in Perplexity?” Growth marketers and agency leads get the follow-up: “Show me examples.” This SE Ranking Sheets automation turns that scramble into a repeatable report.
You’ll see what the workflow pulls from SE Ranking AI Search, how it structures prompts/answers/citations, and how to get clean exports you can trust for audits and client reporting.
How This Automation Works
The full n8n workflow, from trigger to final output:
n8n Workflow Template: SE Ranking to Google Sheets, track AI SERP mentions
flowchart LR
subgraph sg0["When clicking ‘Execute workflow’ Flow"]
direction LR
n0@{ icon: "mdi:play-circle", form: "rounded", label: "When clicking ‘Execute workf..", pos: "b", h: 48 }
n1@{ icon: "mdi:swap-vertical", form: "rounded", label: "Set the Input Fields", pos: "b", h: 48 }
n2@{ icon: "mdi:cog", form: "rounded", label: "Write File to Disk", pos: "b", h: 48 }
n3@{ icon: "mdi:code-braces", form: "rounded", label: "Create a Binary Data", pos: "b", h: 48 }
n4["<div style='background:#f5f5f5;padding:10px;border-radius:8px;display:inline-block;border:1px solid #e0e0e0'><img src='https://flowpast.com/wp-content/uploads/n8n-workflow-icons/code.svg' width='40' height='40' /></div><br/>Extract All Links"]
n5["<div style='background:#f5f5f5;padding:10px;border-radius:8px;display:inline-block;border:1px solid #e0e0e0'><img src='https://flowpast.com/wp-content/uploads/n8n-workflow-icons/code.svg' width='40' height='40' /></div><br/>Extract Prompts with Answers"]
n6["<div style='background:#f5f5f5;padding:10px;border-radius:8px;display:inline-block;border:1px solid #e0e0e0'><img src='https://flowpast.com/wp-content/uploads/n8n-workflow-icons/code.svg' width='40' height='40' /></div><br/>Extract JSON"]
n7["<div style='background:#f5f5f5;padding:10px;border-radius:8px;display:inline-block;border:1px solid #e0e0e0'><img src='https://flowpast.com/wp-content/uploads/n8n-workflow-icons/httprequest.dark.svg' width='40' height='40' /></div><br/>SE Ranking AI Request by Brand"]
n8["<div style='background:#f5f5f5;padding:10px;border-radius:8px;display:inline-block;border:1px solid #e0e0e0'><img src='https://flowpast.com/wp-content/uploads/n8n-workflow-icons/merge.svg' width='40' height='40' /></div><br/>Merge Responses"]
n6 --> n8
n8 --> n3
n4 --> n8
n3 --> n2
n1 --> n7
n5 --> n8
n7 --> n4
n7 --> n5
n7 --> n6
n0 --> n1
end
%% Styling
classDef trigger fill:#e8f5e9,stroke:#388e3c,stroke-width:2px
classDef ai fill:#e3f2fd,stroke:#1976d2,stroke-width:2px
classDef aiModel fill:#e8eaf6,stroke:#3f51b5,stroke-width:2px
classDef decision fill:#fff8e1,stroke:#f9a825,stroke-width:2px
classDef database fill:#fce4ec,stroke:#c2185b,stroke-width:2px
classDef api fill:#fff3e0,stroke:#e65100,stroke-width:2px
classDef code fill:#f3e5f5,stroke:#7b1fa2,stroke-width:2px
classDef disabled stroke-dasharray: 5 5,opacity: 0.5
class n0 trigger
class n7 api
class n3,n4,n5,n6 code
classDef customIcon fill:none,stroke:none
class n4,n5,n6,n7,n8 customIcon
The Problem: AI SERP mentions are hard to track (and harder to prove)
Traditional rank tracking tells you where pages sit for keywords. It does not tell you how AI engines describe your brand, which sources they cite, or which prompts trigger your mention. So when someone says “AI search is stealing clicks,” you’re stuck doing the worst kind of work: manual spot-checks, screenshots, and messy copy-pastes from AI answers that change next week. Then comes the real pain. You try to compare outputs across prompts, regions, or engines and realize none of it is structured, which means reporting turns into a spreadsheet cleanup project.
The friction compounds. Here’s where it breaks down.
- People end up manually reviewing dozens of AI answers just to find a single brand mention.
- Citations and reference links are scattered, so verifying “why you showed up” takes forever.
- Every analyst formats the data differently, which makes trends impossible to spot quarter over quarter.
- When leadership asks for an export-ready dataset, you’re left with screenshots and vibes instead of evidence.
The Solution: Pull SE Ranking AI Search data into structured outputs
This workflow takes SE Ranking’s AI Search data (real prompts, AI-generated answers, and the sources/citations that support those answers) and turns it into a normalized dataset you can actually use. You kick it off by providing a brand name and a few AI search parameters, like engine choice and result limits. n8n calls the SE Ranking API, then processes the response in a few “cleanup” passes that extract reference URLs, gather the prompt answers, and assemble a consistent JSON structure. Finally, it merges everything into one unified output and saves a clean JSON file you can analyze, archive, or feed into reporting. It’s brand intelligence you can run again next week without redoing the messy parts.
The workflow starts with input fields for your brand and AI search settings. Then it fetches AI Search prompts and responses from SE Ranking, extracts the citations, and consolidates everything. At the end, you get a single structured export you can push into Google Sheets (or keep as JSON for audits).
What You Get: Automation vs. Results
| What This Workflow Automates | Results You’ll Get |
|---|---|
|
|
Example: What This Looks Like
Say you track one brand across 30 AI prompts each week, and you need the answer plus the citations. Manually, even a “quick” review is maybe 5 minutes per prompt once you copy the text, grab sources, and format it, so you’re looking at about 2.5 hours. With this workflow, you enter the brand parameters once (about 5 minutes), let the API run and processing happen in the background (often 10–20 minutes depending on limits), and you end with a structured export ready to paste into a Google Sheet. That’s roughly 2 hours back, every week, and the data is more consistent.
What You’ll Need
- n8n instance (try n8n Cloud free)
- Self-hosting option if you prefer (Hostinger works well)
- SE Ranking for AI Search API access.
- Google Sheets to analyze and share results.
- SE Ranking API key (get it from your SE Ranking account dashboard)
Skill level: Intermediate. You’ll connect an API credential, adjust a few fields, and update an export destination.
Don’t want to set this up yourself? Talk to an automation expert (free 15-minute consultation).
How It Works
You start the run with a brand and AI search settings. In n8n, the workflow begins at a manual trigger, then sets your input fields (brand name, engine, region/source, sorting, result limits).
SE Ranking is queried for AI Search data. An HTTP request calls the SE Ranking endpoint and returns the AI SERP payload, including prompts, answers, and the underlying JSON you’d normally have to inspect by hand.
The workflow cleans and structures the response. Code steps extract reference URLs, gather prompt answers, and assemble a consistent prompt-level JSON object so each row of data has the same “shape” when you export it.
A unified export is generated. The workflow merges all output streams, builds a binary payload, and writes the final JSON to disk so you can load it into Google Sheets or Excel for reporting.
You can easily modify the input fields to switch brands, compare AI engines, or change the result limits based on your needs. See the full implementation guide below for customization options.
Step-by-Step Implementation Guide
Step 1: Configure the Manual Trigger
This workflow starts with a manual trigger so you can run it on demand during setup and testing.
- Add the Manual Run Trigger node to start the workflow manually.
- Connect Manual Run Trigger to Configure Input Fields as the first step in the flow.
Step 2: Connect the Brand Prompt API
Provide the search parameters and authenticate the API request that powers the brand SERP insights.
- In Configure Input Fields, add your input parameters such as brand set to
LinkedIn, engine set toperplexity, source set tous, sort set tovolume, sort_order set todesc, offset set to0, and limit set to10. - Set advanced filters in Configure Input Fields with multi_keyword_included set to
[ [ { "type": "contains", "value": "seo" } ] ]and multi_keyword_excluded set to[ [ { "type": "contains", "value": "seo" }, { "type": "contains", "value": "tools" } ], [ { "type": "contains", "value": "backlinks" } ] ]. - Open Brand Prompt API Call and set URL to
https://api.seranking.com/v1/ai-search/prompts-by-brand. - In Brand Prompt API Call, enable Send Query and map query parameters to the input fields using expressions like
{{ $json.brand }},{{ $json.source }},{{ $json.engine }},{{ $json.sort }},{{ $json.sort_order }},{{ $json.offset }}, and{{ $json.limit }}. - Credential Required: Connect your httpHeaderAuth credentials in Brand Prompt API Call (this node is configured to use genericCredentialType with httpHeaderAuth).
⚠️ Common Pitfall: Ensure the query parameter expressions match the field names created in Configure Input Fields, otherwise the API call will return empty results.
Step 3: Set Up the Parallel Processing Nodes
The API response splits into parallel processing streams to extract links, answers, and prompt data.
- Connect Brand Prompt API Call so it outputs to Collect Reference URLs, Gather Prompt Answers, and Assemble Prompt JSON in parallel.
- In Collect Reference URLs, keep the JavaScript code that flattens and filters valid links from the API response.
- In Gather Prompt Answers, keep the JavaScript that builds an array of
{ prompt, answer }objects from the response. - In Assemble Prompt JSON, keep the code that wraps data as
{ prompts_with_links: data }.
Brand Prompt API Call outputs to both Collect Reference URLs and Gather Prompt Answers and Assemble Prompt JSON in parallel.
Step 4: Combine and Save the Output
Merge all processing outputs into a single JSON payload, convert it to binary, and save it to disk.
- Configure Combine Output Streams with Mode set to
combine, Combine By set tocombineByPosition, and Number Inputs set to3. - Connect Collect Reference URLs, Gather Prompt Answers, and Assemble Prompt JSON into Combine Output Streams at inputs 1, 2, and 3 respectively.
- In Build Binary Payload, keep the function code that converts the combined JSON into base64 binary data for file writing.
- In Save JSON to Disk, set Operation to
write, File Name to=C:\\SERanking_ByBrand.json, and Data Property Name to=data.
⚠️ Common Pitfall: The path C:\SERanking_ByBrand.json writes to the n8n host file system. Ensure your n8n instance has write permissions to this location.
Step 5: Test and Activate Your Workflow
Run a manual execution to verify outputs and then activate the workflow for use.
- Click Execute Workflow to run Manual Run Trigger and observe the data in each node.
- Confirm Brand Prompt API Call returns a list of prompts and that the three parallel branches produce links, answers, and prompt JSON.
- Verify Save JSON to Disk creates
SERanking_ByBrand.jsoncontaining the combined output. - When the test is successful, toggle the workflow to Active for production use.
Common Gotchas
- SE Ranking credentials can expire or need specific permissions. If things break, check your HTTP Header authentication token format in n8n credentials first.
- If you’re using Wait nodes or external rendering, processing times vary. Bump up the wait duration if downstream nodes fail on empty responses.
- Writing JSON to disk fails more than people expect. Confirm the “Write File to Disk” path exists and that your server user has write permissions.
Frequently Asked Questions
About 30 minutes if you already have your SE Ranking API key.
No. You’ll mainly paste credentials and adjust a few fields. The code steps are already built into the workflow.
Yes. n8n has a free self-hosted option and a free trial on n8n Cloud. Cloud plans start at $20/month for higher volume. You’ll also need to factor in SE Ranking API costs based on your plan.
Two options: n8n Cloud (managed, easiest setup) or self-hosting on a VPS. For self-hosting, Hostinger VPS is affordable and handles n8n well. Self-hosting gives you unlimited executions but requires basic server management.
Yes, and it’s the point of doing this in n8n. Update the values in the “Configure Input Fields” step, then the “Brand Prompt API Call” will pull a different engine, region/source, sorting preference, or result limit. Common tweaks include swapping the brand to a competitor, running the same prompt set across two engines to compare narratives, and adding an OpenAI step to tag prompts (pricing, reviews, comparisons). If you want the output in Google Sheets instead of a JSON file, replace the “Save JSON to Disk” step with a Google Sheets append action and map the fields you care about.
Usually it’s the header auth format. SE Ranking expects a token prefix plus your API key, so check the HTTP Header authentication in n8n and re-save the credential. If the key is correct, look for account permissions or request limits on the SE Ranking side, especially when you increase result limits.
As many as your SE Ranking API limits and n8n execution capacity allow.
Often, yes. This workflow relies on shaping API responses and merging multiple data streams, which is where n8n is frankly easier to control and cheaper to scale, especially if you self-host. Zapier or Make can work if you only need a simple “call API then paste into a sheet,” but they get awkward once you want consistent JSON normalization, branching, or file exports. n8n also gives you more visibility into what broke when an API response changes, which happens in real life. If you’re unsure, Talk to an automation expert and get a recommendation based on your reporting needs.
Once this is running, AI SERP monitoring stops being a fire drill and becomes a simple habit. The workflow handles the repetitive collection and formatting so you can focus on the narrative, the gaps, and what to do next.
Need Help Setting This Up?
Our automation experts can build and customize this workflow for your specific needs. Free 15-minute consultation—no commitment required.