Automate SEO Content Brief Generator: Full Brief with Live Competitor Analysis in n8n — Step by Step
You type a keyword into a workflow, and 60 seconds later you have a complete content brief: H2/H3 outline, target word count pulled from what's actually ranking, LSI keywords, an FAQ block sourced fro
You type a keyword into a workflow, and 60 seconds later you have a complete content brief: H2/H3 outline, target word count pulled from what's actually ranking, LSI keywords, an FAQ block sourced from real search behavior, and a list of subtopics your top three competitors forgot to cover. No opening a dozen browser tabs. No manually reading five SERP results and eyeballing their headings. That is what a well-built SEO Content Brief Generator does inside n8n — and this article shows you exactly how to assemble one, node by node.
The problem: briefs are the bottleneck, not the writing
Most content teams think their constraint is writing speed. It isn't. The constraint is the 45–90 minutes of research that has to happen before a writer touches the doc. Someone has to pull the SERP, read the top-ranking pages, count their word length, extract the recurring H2s, harvest the "People Also Ask" questions, and figure out which angles are saturated versus wide open. Skip that step and you get generic content that ranks nowhere. Do it manually and you cap your output at a handful of briefs per week per person.
The pain is worse for lean teams. A technical founder writing their own content, or a two-person ops team supporting five writers, cannot afford to spend a full afternoon researching a single keyword. The result is predictable: briefs get rushed, competitor analysis gets skipped entirely, and content ships without knowing what it's actually competing against. You end up publishing into a gap that was never validated — or worse, into a topic three competitors already own with 3,000-word guides.
Competitor analysis is the part that gets cut first because it's the most tedious. And it's the single highest-leverage input to a brief. If you know the top result is 2,400 words with eight H2s and never mentions pricing, you know exactly where your gap is. That intelligence is what turns a mediocre brief into a rankable one.
The solution: a live-research pipeline in n8n
The fix is to treat brief generation as a data pipeline, not a writing task. You feed in one keyword. The workflow fetches the live SERP, scrapes the ranking pages, extracts their structure, pulls the "People Also Ask" questions, and hands all of that raw intelligence to an LLM with a strict prompt that outputs a structured brief. Because the research is live, every brief reflects what's ranking today — not a snapshot from a keyword tool that refreshes monthly.
The architecture is deliberately simple: a trigger, a SERP fetch, a scrape-and-parse step over the top results, an aggregation step, an AI generation step, and a delivery step. Each piece is a standard n8n node or a small block of them. Nothing here requires custom infrastructure — it runs on a self-hosted n8n instance or n8n Cloud, and the only external dependencies are a SERP data source and an LLM API.
Step-by-step setup in n8n
Here is the node-by-node build. Assume you're on n8n 1.x with the AI nodes available.
1. Trigger — Form Trigger node. Use the Form Trigger node so anyone on the team can submit a keyword from a hosted form. Add a single required field named keyword and, optionally, a target_market field to localize results. If you'd rather drive it from a spreadsheet, swap in a Google Sheets Trigger watching a "keywords to brief" tab.
2. Fetch the SERP — HTTP Request node. Add an HTTP Request node pointing at a SERP API (SerpApi, DataForSEO, or Serper.dev all work). Method GET, pass {{ $json.keyword }} as the query parameter, and store your API key as a credential rather than hardcoding it. Set num=10 so you capture the full first page. This returns the organic results plus the "People Also Ask" block — both matter.
3. Isolate the top competitors — Item Lists / Code node. Use an Edit Fields (Set) node or a small Code node to slice the organic results down to the top 3–5 URLs. Map them into individual items so the next step runs once per competitor. Filter out obvious non-competitors here (YouTube, Reddit, marketplace listings) if your niche needs it.
4. Scrape each ranking page — HTTP Request + HTML Extract. Loop the URLs through a second HTTP Request node to fetch each page's raw HTML, then pipe into the HTML (Extract) node. Configure extraction rules to pull h1, h2, and h3 elements and the full body text. From the body text you compute word count in a Code node (text.split(/\s+/).length). Now you have, for each competitor: its heading structure and its length. Wrap this branch so a single failed fetch doesn't kill the run — enable "Continue On Fail" on the request node.
5. Aggregate the intelligence — Merge / Aggregate node. Use an Aggregate node to collapse all competitor data into one item: an array of heading structures, an array of word counts, and the PAA questions from step 2. Compute a median or average target word count here so the brief has a concrete number to recommend.
6. Generate the brief — AI Agent / Basic LLM Chain node. Add a Basic LLM Chain or AI Agent node connected to a Claude model (Claude Sonnet is the right cost/quality balance for this). Feed it the aggregated competitor headings, the word-count target, and the PAA questions. Your system prompt should be strict: "You are an SEO strategist. Using the competitor data provided, output a JSON brief with: recommended_title, target_word_count, h2_outline (each with nested h3s), lsi_keywords, faqs, and content_gaps — subtopics that appear in search intent but that NONE of the competitors covered." Set the node to return JSON so downstream steps can parse it cleanly. Attach a Structured Output Parser to enforce the schema.
7. Deliver — Google Docs / Notion / Email node. Route the structured brief to wherever your writers live. A Google Docs node creates a formatted doc; a Notion node appends a database row; a Send Email node drops it in an inbox. Include the raw competitor word counts and headings in an appendix so the writer can sanity-check the AI's recommendations.
That's the whole pipeline. Seven logical stages, all standard nodes, and it runs end to end in under a minute per keyword.
Why this beats a keyword tool or a bare ChatGPT prompt
It's live, not cached. Keyword tools refresh their SERP snapshots on a schedule. This workflow reads the results at the moment you run it, so a brief for a fast-moving topic reflects reality, not last month.
The competitor analysis is real, not hallucinated. Ask an LLM alone to "analyze competitors for keyword X" and it invents plausible-sounding pages. Here, the LLM only reasons over HTML you actually scraped — the headings and word counts are ground truth, so the gaps it identifies are real gaps.
It scales linearly. One brief or fifty briefs cost the same per unit of human time: zero. Point the Google Sheets trigger at a list of 40 keywords and walk away. Your throughput stops being a function of headcount.
It's consistent. Every brief follows the same schema, so writers always know where to find the outline, the word target, and the gaps. No more "which analyst made this and did they include FAQs?"
It runs on infrastructure you control. Self-hosted n8n means the workflow, credentials, and data stay on your server. Nothing about your keyword strategy leaks to a third-party SaaS dashboard.
Common pitfalls and how to avoid them
Getting blocked while scraping. Raw HTTP Request fetches against big sites will sometimes hit bot protection. Set a realistic User-Agent header, add a small delay between requests, and route through the SERP API's own page-fetch endpoint if it offers one. Always enable "Continue On Fail" so one blocked page doesn't abort the brief.
Letting the LLM invent word counts. If you don't feed a real target number, the model guesses. Always compute the median competitor length in a Code node and pass it explicitly. Instruct the prompt to recommend "10–20% above the median" rather than picking an arbitrary figure.
Unstructured output that breaks delivery. Without a Structured Output Parser, the AI node returns prose that your Google Docs node can't map. Enforce JSON output and validate the schema before the delivery step — add an IF node that checks the required keys exist and re-runs the generation on failure.
Thin PAA data. Some SERP APIs return sparse "People Also Ask" blocks. If FAQ quality matters, make a second API call for related searches and merge both sources before generation.
Ignoring intent mismatch. A keyword can have mixed intent (informational vs. transactional). Have the prompt classify the dominant intent from the competitor titles first, then build the outline to match — otherwise you brief an article that fights the SERP instead of fitting it.
Build this once and every future brief costs you a keyword and sixty seconds. That's the difference between a team that researches every piece of content and one that ships blind.
Ja construimos isso pra voce
Nao comece do zero. O SEO Content Brief Generator: Full Brief with Live Competitor Analysis e um workflow n8n pronto para instalar — conecta suas ferramentas em minutos, sem codigo.
Instalar por $49.0 →