🔓 Unlock all 10,000+ workflows & prompts free Join Newsletter →
✅ Full access unlocked — explore all 10,000 AI workflow and prompt templates Browse Templates →
Home n8n Workflow
January 22, 2026

DataForSEO to Google Sheets, keyword history built

Lisa Granqvist Partner Workflow Automation Expert

Keyword research gets messy fast. You run a report, paste results into a sheet, tweak columns, lose the date, then do it again next week and nothing lines up.

Content marketers feel it when planning goes slow. SEO specialists feel it when tracking becomes guesswork. And agency leads feel it when every client needs “one more export.” This DataForSEO Sheets automation turns that chaos into a clean, dated history you can actually use.

You’ll set up an n8n workflow that pulls keyword, SERP, and People Also Ask insights from DataForSEO and appends them into the right Google Sheet, every run. No column drift. No missing context.

How This Automation Works

Here’s the complete workflow you’ll be setting up:

n8n Workflow Template: DataForSEO to Google Sheets, keyword history built

Why This Matters: Keyword Research Without the Spreadsheet Spiral

SEO research isn’t hard because the data is unavailable. It’s hard because the workflow around the data is fragile. One teammate exports SERPs into a CSV, another pastes “People Also Ask” into a separate tab, and someone else renames columns to match their personal template. A week later you try to compare trends and realize the sheet is a patchwork. Worse, the date is missing, so you can’t tell if a ranking shift happened last Tuesday or three months ago. That’s how good content opportunities slip through the cracks.

The friction compounds. These are the spots where it usually breaks down.

  • Exports don’t match your sheet structure, so every run starts with cleanup.
  • SERP and PAA insights live in different places, which means planning happens without the full picture.
  • When dates aren’t consistently logged, “trend tracking” becomes a hunch, not a process.
  • Manual copy-paste invites small errors that quietly ruin comparisons and reporting.

What You’ll Build: DataForSEO Insights Logged to Sheets Automatically

This workflow gives you one repeatable pipeline for SEO research. It starts with a simple form submission inside n8n (or a scheduled run) where you choose what type of research you want, like related keywords, keyword suggestions, autocomplete ideas, subtopics, or People Also Ask questions. n8n then sends the right HTTP requests to DataForSEO, pulls back the raw JSON response, and normalizes it into clean rows. If the Google Sheet (or the specific tab for that operator) doesn’t exist yet, the workflow creates it for you. Finally, it appends the results with consistent columns and a date, so each run becomes part of a growing keyword history instead of a one-off export.

The workflow kicks off from the form trigger, validates your inputs, then routes the request through a switch that selects the right DataForSEO endpoint. After the data is expanded into individual items, n8n maps fields into a standard shape and appends rows into the matching Google Sheet tab.

What You’re Building

Expected Results

Say you research 20 keywords each week and you usually pull five datasets per keyword (related, suggestions, autocomplete, subtopics, and PAA). If you spend roughly 3 minutes exporting, formatting, and pasting each dataset, that’s about 300 minutes, or 5 hours a week. With this workflow, you submit the request once and let n8n append everything to the right Google Sheet tab; your “time spent” becomes closer to 10 minutes of setup and review. That’s a real afternoon back, every week.

Before You Start

  • n8n instance (try n8n Cloud free)
  • Self-hosting option if you prefer (Hostinger works well)
  • DataForSEO account for keyword and SERP data access.
  • Google Sheets to store and track keyword history.
  • DataForSEO API credentials (get them from your DataForSEO dashboard).

Skill level: Beginner. You’ll connect accounts, paste credentials, and edit a few fields like location and language.

Want someone to build this for you? Talk to an automation expert (free 15-minute consultation).

Step by Step

A form submission triggers the run. You enter the keyword (or keyword set) and pick the operation type, like Related Keywords, Suggestions, Autocomplete, Subtopics, or PAA.

Your inputs are validated and mapped. An If node checks required fields so you don’t waste API calls on blank keywords. Then a Set node standardizes what the rest of the workflow expects, which keeps the downstream mapping stable.

n8n routes to the correct DataForSEO endpoint. A switch chooses the right branch, then HTTP Request nodes fetch the dataset you selected. Split-out and batching steps expand the API response into row-shaped items so it’s easy to store.

Google Sheets tabs are created and filled. For each operator, the workflow creates the related sheet if needed, maps fields into consistent columns, then appends rows with a date so your history grows over time.

You can easily modify the operator options to add SERP analysis or competitor research based on your needs. See the full implementation guide below for customization options.

Step-by-Step Implementation Guide

Step 1: Configure the Form Trigger

Set up the form that collects the keyword, location, language, and operation type from users.

  1. Add the Form Submission Trigger node as the workflow trigger.
  2. Set Form Title to SEO Related Keyword Finder🚀 and Form Description to ✏️ Enter your target keyword\n📍 Choose the location\n🌐 Select the language.
  3. Configure fields for keyword, location_name (dropdown), language_name (dropdown), and Operation (dropdown).
  4. Optional: Keep the options.customCss styling if you want the neon theme applied to the form.

Step 2: Validate and Map Incoming Data

Validate required inputs and normalize field names for downstream nodes.

  1. In Validate Input Fields, keep the four notEmpty checks for {{$json.keyword}}, {{$json.location_name}}, {{$json.language_name}}, and {{$json.Operation}}.
  2. In Map Request Fields, create assignments to map operation to {{$json.Operation}}, keyword to {{$json.keyword}}, location_name to {{$json.location_name}}, and language_name to {{$json.language_name}}.

Step 3: Connect Google Sheets and Log the Summary

Write the incoming request to a summary sheet, then route the workflow based on the chosen operation.

  1. Open Append Summary Row and set Operation to append with Authentication set to serviceAccount.
  2. Map columns: Time to {{$('Form Submission Trigger').item.json.submittedAt}}, keyword to {{$json.keyword}}, operation to {{$json.operation}}, language_name to {{$json.language_name}}, and location_name to {{$json.location_name}}.
  3. Credential Required: Connect your googleApi credentials in Append Summary Row.
  4. In Route Operation Type, keep the rules that match related keywords🔑, keyword suggestion💡, get autocomplete🧩, get subtopics📚, and people also ask🔍 on {{$json.operation}}.

Tip: The workflow uses one Google Sheet document (document ID [YOUR_ID]) and creates new tabs per operation using {{$json.keyword}} [{{$json.operation}}] as the title.

Step 4: Configure Related Keywords Path

This path creates a sheet tab and fetches related keywords from DataForSEO, then appends rows.

  1. In Create Related Sheet, set Operation to create and Title to ={{ $json.keyword }} [{{ $json.operation }}].
  2. Credential Required: Connect your googleApi credentials in Create Related Sheet.
  3. In Related Keywords API, keep URL as https://api.dataforseo.com/v3/dataforseo_labs/google/related_keywords/live and the JSON Body with {{$('Route Operation Type').item.json.keyword}}, {{$('Route Operation Type').item.json.location_name}}, and {{$('Route Operation Type').item.json.language_name}}.
  4. Credential Required: Connect your httpBasicAuth credentials in Related Keywords API.
  5. In Expand Related Items, set Field To Split Out to tasks[0].result[0].items.
  6. In Map Related Fields, map fields like related keyword to {{ $json.keyword_data.keyword }} and SERP Analysis to {{$json.keyword_data.serp_info.serp_item_types.join(",")}}.
  7. In Append Related Rows, set Operation to append and Sheet Name to ={{ $('Create Related Sheet').item.json.sheetId }}.
  8. Credential Required: Connect your googleApi credentials in Append Related Rows.

Step 5: Configure Suggestions and Autocomplete Paths

Set up the keyword suggestion and autocomplete branches that create sheets, call APIs, split results, map fields, and append rows.

  1. For the suggestions branch, configure Create Suggestion Sheet with Title ={{ $json.keyword }} [{{ $json.operation }}] and set Operation to create.
  2. Credential Required: Connect your googleApi credentials in Create Suggestion Sheet and Append Suggestion Rows.
  3. In Keyword Suggestion API, keep the URL https://api.dataforseo.com/v3/dataforseo_labs/google/keyword_suggestions/live and JSON body with the same {{$('Route Operation Type').item.json.*}} expressions.
  4. Credential Required: Connect your httpBasicAuth credentials in Keyword Suggestion API.
  5. For autocomplete, configure Create Autocomplete Sheet and keep Title as ={{ $json.keyword }} [{{ $json.operation }}].
  6. In Autocomplete API, keep URL https://api.dataforseo.com/v3/serp/google/autocomplete/live/advanced and JSON body with client set to gws-wiz-serp.
  7. Credential Required: Connect your httpBasicAuth credentials in Autocomplete API and your googleApi credentials in Append Autocomplete Rows.

Tip: The Expand Suggestion Items and Expand Autocomplete Items nodes both use tasks[0].result[0].items for split-out, so confirm the API responses include that array.

Step 6: Configure Subtopics and People Also Ask Paths

Set up the subtopics and PAA branches that generate topical ideas and questions.

  1. In Create Subtopics Sheet and Create PAA Sheet, keep Title set to ={{ $json.keyword }} [{{ $json.operation }}] and Operation set to create.
  2. Credential Required: Connect your googleApi credentials for Create Subtopics Sheet, Append Subtopic Rows, Create PAA Sheet, and Append PAA Rows.
  3. In Subtopics API, keep URL https://api.dataforseo.com/v3/content_generation/generate_sub_topics/live and the JSON body with {{ $('Route Operation Type').item.json.keyword }}.
  4. Credential Required: Connect your httpBasicAuth credentials in Subtopics API and People Also Ask API.
  5. In People Also Ask API, update URL from https://api.dataforseo.[CONFIGURE_YOUR_API_KEY] to your real endpoint before testing.
  6. Keep Filter PAA Type set to filter on {{$json.type}} equals people_also_ask, then split with Expand PAA Details using items.

⚠️ Common Pitfall: If People Also Ask API still has [CONFIGURE_YOUR_API_KEY] in the URL, the request will fail. Replace it with your actual DataForSEO endpoint.

Step 7: Test and Activate Your Workflow

Run a manual test to verify each branch writes to its respective sheet and then activate the workflow.

  1. Click Execute Workflow and submit the Form Submission Trigger form with a keyword, location, language, and one operation.
  2. Confirm Append Summary Row adds a new row in the summary sheet and that the appropriate operation path runs.
  3. Verify that the operation-specific sheet is created (e.g., by Create Related Sheet) and that rows are appended (e.g., by Append Related Rows).
  4. If a branch returns no data, inspect the Related Keywords API, Keyword Suggestion API, Autocomplete API, Subtopics API, or People Also Ask API responses for schema changes.
  5. When results look correct, toggle the workflow to Active to enable production use.
🔒

Unlock Full Step-by-Step Guide

Get the complete implementation guide + downloadable template

Troubleshooting Tips

  • Google Sheets credentials can expire or need specific permissions. If things break, check the Google connection in n8n’s Credentials list first, then confirm the account can create and edit the target spreadsheet.
  • If you’re using Wait nodes or external rendering, processing times vary. Bump up the wait duration if downstream nodes fail on empty responses.
  • OpenAI prompts in AI nodes are generic. Add your brand voice early or you’ll be editing outputs forever.

Quick Answers

What’s the setup time for this DataForSEO Sheets automation automation?

About 30 minutes if your DataForSEO and Google accounts are ready.

Is coding required for this keyword history automation?

No. You’ll mostly connect credentials and adjust a few mapped fields. The workflow already handles the API requests and formatting.

Is n8n free to use for this DataForSEO Sheets automation 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 DataForSEO API usage costs based on how many keywords and endpoints you hit per run.

Where can I host n8n to run this automation?

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.

Can I modify this DataForSEO Sheets automation workflow for different use cases?

Yes, and it’s the main reason this template is useful. You can add a SERP branch by extending the “Route Operation Type” switch and duplicating the pattern you already have (Create Sheet → HTTP Request → Split Out → Map Fields → Append Rows). Common customizations include changing the location_code and language_code, logging extra columns like CPC or competition, and adding an AI Agent step to summarize “what changed since last run.” If you want competitor research, you can route to a different DataForSEO endpoint and write to its own tab so your sheets stay readable.

Why is my Google Sheets connection failing in this workflow?

Usually it’s an OAuth permission issue or an expired token. Reconnect your Google Sheets credential in n8n, then confirm the account can create new spreadsheets and edit existing ones. If the sheet lives in a shared drive, make sure that same Google account has access there too.

What volume can this DataForSEO Sheets automation workflow process?

A few hundred keywords per run is typical, and you can scale up with batching.

Is this DataForSEO Sheets automation automation better than using Zapier or Make?

Often, yes. This workflow relies on routing, item expansion, and consistent field mapping, and n8n handles that kind of multi-branch logic without turning it into a pricing problem. You also get self-hosting, which matters when you’re running lots of keyword pulls. Zapier or Make can still be fine for a simple “one endpoint to one sheet” job, but they get clunky when you’re splitting items and writing to multiple tabs. If you’re not sure, Talk to an automation expert and we’ll sanity-check your use case.

Once this is running, your SEO research stops being a pile of exports and starts acting like a system. Set it up, keep the history, and plan content from one sheet you actually trust.

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.

Lisa Granqvist

Workflow Automation Expert

Expert in workflow automation and no-code tools.

×

Use template

Get instant access to this n8n workflow Json file

💬
Get a free quote today!
Get a free quote today!

Tell us what you need and we'll get back to you within one working day.

Get a free quote today!
Get a free quote today!

Tell us what you need and we'll get back to you within one working day.

Launch login modal Launch register modal