AutomationFlowsGeneral › AI Keyword Research via Google Autocomplete

AI Keyword Research via Google Autocomplete

Original n8n title: Wait Code (http Request) #3

Wait Code. Uses httpRequest, splitInBatches, stickyNote, chatTrigger. Chat trigger; 11 nodes.

Chat trigger trigger★★★★☆ complexityAI-powered11 nodesHTTP RequestChat Trigger
General Trigger: Chat trigger Nodes: 11 Complexity: ★★★★☆ AI nodes: yes Added:

This workflow follows the Chat Trigger → HTTP Request recipe pattern — see all workflows that pair these two integrations.

The workflow JSON

Copy or download the full n8n JSON below. Paste it into a new n8n workflow, add your credentials, activate. Full import guide →

Download .json
{
  "nodes": [
    {
      "id": "04b7d4d7-6639-4559-9a7a-7eb7b83e16fa",
      "name": "Generate A-Z Queries",
      "type": "n8n-nodes-base.code",
      "notes": "This code adds \n- a blank space\n- and a letter, starting from a, b, c... up to z\nIt processes all the 26 possible letters.\n\nEx :\nn8n a\nn8n b\nn8n c\n...\nn8n z",
      "position": [
        180,
        0
      ],
      "parameters": {
        "jsCode": "const keyword = $input.first().json.chatInput;\nconst alphabet = \"abcdefghijklmnopqrstuvwxyz\".split(\"\");\n\nreturn alphabet.map(letter => ({\n  json: { query: `${keyword} ${letter}` }\n}));"
      },
      "notesInFlow": false,
      "typeVersion": 2
    },
    {
      "id": "0c6ae163-3d08-4a40-aaa9-921f583940df",
      "name": "Google Autocomplete",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        560,
        100
      ],
      "parameters": {
        "url": "=https://suggestqueries.google.com/complete/search?client=firefox&hl=en&oe=utf-8&q={{ $json.query }}",
        "options": {}
      },
      "typeVersion": 4
    },
    {
      "id": "21f0aeaa-2d64-497c-a890-6bd84ade624f",
      "name": "Loop Over Items",
      "type": "n8n-nodes-base.splitInBatches",
      "notes": "The 26 items (one for each alphabet letter) are treated by batches of 10.\nThis setting + the wait time help not to be blocked by Google's API.",
      "position": [
        360,
        0
      ],
      "parameters": {
        "options": {},
        "batchSize": 10
      },
      "typeVersion": 3
    },
    {
      "id": "6fca90c9-c8f0-4a86-b746-2eedd670404a",
      "name": "Wait 1s",
      "type": "n8n-nodes-base.wait",
      "notes": "This wait time is necessary, otherwise Google API might block the call and make an error.",
      "position": [
        920,
        100
      ],
      "parameters": {
        "unit": "seconds"
      },
      "typeVersion": 1
    },
    {
      "id": "1a1a1a69-736b-4353-9353-bf80b4082f2c",
      "name": "Code",
      "type": "n8n-nodes-base.code",
      "position": [
        740,
        100
      ],
      "parameters": {
        "jsCode": "const data = JSON.parse($json.data);\nreturn {\n  json: {\n    keywords: data[1]\n  }\n};\n"
      },
      "typeVersion": 2
    },
    {
      "id": "6af6e3e1-85b7-49a7-8589-bf49d34ff429",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -40,
        -340
      ],
      "parameters": {
        "width": 400,
        "height": 320,
        "content": "## Type a Keyword and Discover What People Search on Google\n\nThis workflow scrapes Google autocomplete results by combining **your keyword** with every letter from **A to Z**.\n\n**Example:**  \nKeyword: `n8n`  \nResults:  \n- n8n agent  \n- n8n automation  \n- n8n api  \n- ...and so on\n"
      },
      "typeVersion": 1
    },
    {
      "id": "87673f0f-19ef-4bf7-a2bb-6d7e823a4f57",
      "name": "Get Keyword",
      "type": "@n8n/n8n-nodes-langchain.chatTrigger",
      "notes": "You could also get this initial keyword from :\n- a line in a Google Sheet\n- a webhook and a form on a website\n- a messaging app like Telegram or Whatsapp",
      "position": [
        0,
        0
      ],
      "parameters": {
        "options": {}
      },
      "notesInFlow": false,
      "typeVersion": 1.1
    },
    {
      "id": "ce6f882e-69dc-41a4-a9bf-b4fd6c55b87f",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        740,
        -360
      ],
      "parameters": {
        "width": 480,
        "height": 240,
        "content": "## Exporting the Keywords\n\nYou can easily add a node to export the keywords in various ways:\n\n- via a webhook\n- by email\n- as a file (e.g., saved to Google Drive)\n- directly to a website"
      },
      "typeVersion": 1
    },
    {
      "id": "2675a52d-1018-4d33-914d-fc46225a3cc5",
      "name": "Extract Keywords",
      "type": "n8n-nodes-base.code",
      "notes": "This code gathers all the keywords in one list.",
      "position": [
        560,
        -100
      ],
      "parameters": {
        "jsCode": "let mergedKeywords = [];\n\nfor (const item of $input.all()) {\n  mergedKeywords.push(...item.json.keywords);\n}\n\nreturn { json: { keywords: mergedKeywords } };\n"
      },
      "typeVersion": 2
    },
    {
      "id": "95376c0e-43a8-408d-9542-ca9c0c4999c7",
      "name": "Return Keywords",
      "type": "n8n-nodes-base.respondToWebhook",
      "notes": "Use this node",
      "position": [
        740,
        -100
      ],
      "parameters": {
        "options": {}
      },
      "typeVersion": 1
    },
    {
      "id": "9355b89b-5366-4bbb-a06b-081ced4c2134",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        540,
        280
      ],
      "parameters": {
        "width": 560,
        "height": 280,
        "content": "## Adapt the Language\n\nAutocomplete results depend on the selected language.\n\nYou can change the `&hl=en` parameter in the **Google Autocomplete** node.  \nReplace the `\"en\"` part with the language code of your choice.\n\n**Examples:**  \n- `&hl=fr` \u2192 French  \n- `&hl=es` \u2192 Spanish  \n- `&hl=de` \u2192 German\n"
      },
      "typeVersion": 1
    }
  ],
  "connections": {
    "Code": {
      "main": [
        [
          {
            "node": "Wait 1s",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Wait 1s": {
      "main": [
        [
          {
            "node": "Loop Over Items",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Get Keyword": {
      "main": [
        [
          {
            "node": "Generate A-Z Queries",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Loop Over Items": {
      "main": [
        [
          {
            "node": "Extract Keywords",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Google Autocomplete",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Extract Keywords": {
      "main": [
        [
          {
            "node": "Return Keywords",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Google Autocomplete": {
      "main": [
        [
          {
            "node": "Code",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Generate A-Z Queries": {
      "main": [
        [
          {
            "node": "Loop Over Items",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
Pro

For the full experience including quality scoring and batch install features for each workflow upgrade to Pro

How this works

This workflow enables you to generate and process a comprehensive list of keyword suggestions from Google Autocomplete, starting with a single seed term you provide via chat, saving hours of manual research for SEO specialists and content creators. It automatically expands your input into A-Z queries, fetches autocomplete results using the httpRequest node, and loops through them in batches to build an extensive keyword database without overwhelming Google's servers. The key step is the intelligent batching and pausing mechanism, which ensures reliable data collection while respecting rate limits, delivering actionable insights directly back to your chat interface.

Use this workflow when kickstarting keyword research for blog topics, PPC campaigns, or site audits, especially if you need broad autocomplete data quickly from a chat prompt. Avoid it for real-time applications or when precise search volume metrics are required, as it focuses solely on suggestions rather than analytics—pair it with tools like Google Search Console for deeper validation. Common variations include customising the wait times for stricter rate limits or integrating additional filters in the code nodes to target specific locales or query types.

About this workflow

Wait Code. Uses httpRequest, splitInBatches, stickyNote, chatTrigger. Chat trigger; 11 nodes.

Source: https://github.com/Zie619/n8n-workflows — original creator credit. Request a take-down →

More General workflows → · Browse all categories →

Related workflows

Workflows that share integrations, category, or trigger type with this one. All free to copy and import.

General

Testing Mulitple Local LLM with LM Studio. Uses stickyNote, httpRequest, chatTrigger, dateTime. Chat trigger; 21 nodes.

HTTP Request, Chat Trigger, OpenAI Chat +2
General

Testing Mulitple Local LLM with LM Studio. Uses stickyNote, httpRequest, chatTrigger, dateTime. Chat trigger; 21 nodes.

HTTP Request, Chat Trigger, OpenAI Chat +2
General

TopSourcer - Finds LinkedIn Profiles using natural language. Uses chatTrigger, stickyNote, googleSheets, httpRequest. Chat trigger; 18 nodes.

Chat Trigger, Google Sheets, HTTP Request +1
General

🔍🛠️ Tavily Search & Extract - Template. Uses stickyNote, httpRequest, lmChatOpenAi, chainLlm. Chat trigger; 17 nodes.

HTTP Request, OpenAI Chat, Chain Llm +1
General

YouTube Video Transcriber. Uses chatTrigger, respondToWebhook, stickyNote, httpRequest. Chat trigger; 14 nodes.

Chat Trigger, HTTP Request, OpenAI