🔓 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

Google Sheets to WordPress, drafts with images ready

Lisa Granqvist Partner Workflow Automation Expert

Your content pipeline probably isn’t “writing.” It’s hunting for topics, copying briefs into docs, juggling versions, then realizing you still need a featured image before anything can go live. That’s how a simple post turns into a half-day of busywork.

Content marketers feel it when the calendar slips. Agency owners feel it when clients want “more output” without more budget. Even a solo founder trying to stay visible gets stuck. This Sheets WordPress drafts automation turns trends into review-ready drafts (with images) without turning your week into tab-hopping.

You’ll see how the workflow finds a trending topic, logs it in Google Sheets, generates a full draft, then uploads an AI image and assigns it as the featured media in WordPress.

How This Automation Works

The full n8n workflow, from trigger to final output:

n8n Workflow Template: Google Sheets to WordPress, drafts with images ready

The Problem: Drafting content is the easy part

Most teams don’t struggle because they can’t write. They struggle because “publish a post” is actually 15 tiny tasks spread across tools. Someone has to pick a topic that’s worth writing about, keep a backlog you can trust, generate or outline content, format it for WordPress, then deal with images and metadata. And the moment you skip any step, quality drops or things ship half-finished. Honestly, that’s where consistency dies: not in creativity, but in process.

The friction compounds, especially once you’re trying to do this every week.

  • Trending topics get discussed in Slack or meetings, then vanish because there’s no queue.
  • Drafts end up inconsistent, since every writer starts from a different template.
  • Featured images become a last-minute scramble, so posts sit in “almost ready” status.
  • Copy-paste formatting into WordPress introduces weird spacing, broken headings, and avoidable edits.

The Solution: A tracked pipeline from trend → WordPress draft

This n8n workflow creates a simple, repeatable content machine using tools you probably already understand. You launch it, and Perplexity AI scans the last day or two of developer and security news to surface a topic that’s actually trending. That topic gets cleaned up, then written into a Google Sheet so you have a living queue instead of scattered notes. Next, Perplexity generates the post itself (title, sections, keywords, and meta description), and the workflow converts that output into structured data your tools can use. From there, n8n creates a WordPress draft for review, generates a featured image via HuggingFace FLUX, uploads the image to WordPress Media, and attaches it to the draft automatically. No publishing without approval. You stay in control.

The workflow starts with trend discovery and a clean backlog in Google Sheets. Then it generates content and creates a WordPress draft. Finally, it produces an AI image, uploads it, and sets it as the featured media so the post looks complete when you open WordPress.

What You Get: Automation vs. Results

Example: What This Looks Like

Say you want 3 new drafts a week. Manually, a typical cycle might look like 30 minutes to find and validate a topic, about 2 hours to outline and write, then another 30 minutes to format in WordPress and hunt down an image. Call it about 3 hours per post, or roughly 9 hours a week. With this workflow, the “human time” becomes launching the run and reviewing the draft, maybe 15 minutes per post, while generation and image creation happen in the background. You still approve everything, but you’re no longer doing the mechanical parts.

What You’ll Need

  • n8n instance (try n8n Cloud free)
  • Self-hosting option if you prefer (Hostinger works well)
  • Google Sheets for the topic queue and tracking.
  • WordPress to store drafts and upload media.
  • HuggingFace API token (get it from your HuggingFace account settings).

Skill level: Intermediate. You’ll connect accounts, edit a sheet ID and site URL, and paste API tokens.

Don’t want to set this up yourself? Talk to an automation expert (free 15-minute consultation).

How It Works

Manual launch kicks it off. You run the workflow when you want new topics and drafts generated. Some teams do this daily, others batch it twice a week.

Trend discovery and cleanup happen first. Perplexity AI finds a hot topic from the last 24–48 hours, then a small cleanup step turns it into something you’d actually want as a post headline or working title.

Google Sheets becomes your content control center. The workflow appends the topic to your sheet, pulls any pending rows, generates the full post (title, content sections, keywords, meta description), then writes that back to the same row so the status is always visible.

WordPress draft and featured image get created automatically. n8n publishes the content as a draft through the WordPress REST API, generates an image with HuggingFace FLUX, uploads it to Media, then sets that image as the featured media on the draft.

You can easily modify the Google Sheet columns to match your editorial workflow, so you can add things like “reviewer,” “category,” or “internal links” later. See the full implementation guide below for customization options.

Step-by-Step Implementation Guide

Step 1: Configure the Manual Trigger

Set up the manual trigger that starts the workflow and launches the trending topic discovery process.

  1. Add the Manual Workflow Launch node as your trigger.
  2. Keep default settings (no parameters required).
  3. Connect Manual Workflow Launch to Discover Trending Topics to follow the execution flow.

Tip: The Flowpast Branding sticky note is informational only and doesn’t affect execution.

Step 2: Connect Google Sheets

Configure Google Sheets to store and retrieve topics and generated content.

  1. Open Append Topic to Sheets and set Operation to append.
  2. Set Document to [YOUR_ID] and Sheet Name to Sheet1.
  3. Map Topic to {{ $json.snippet }} and is_generated to 0.
  4. Open Retrieve Pending Topics and set the filter to is_generated equals 0.
  5. Open Update Sheet with Content and keep Operation set to update.
  6. Ensure matching column is row_number and keep the mapped expressions such as {{ $json.data.title }} and {{ $json.data.additional_elements.meta_description }}.
  7. Credential Required: Connect your Google Sheets credentials in Append Topic to Sheets, Retrieve Pending Topics, and Update Sheet with Content.

⚠️ Common Pitfall: If [YOUR_ID] isn’t replaced with your actual spreadsheet ID, the workflow will fail on the first Sheets operation.

Step 3: Set Up Perplexity AI Content Generation

Configure the AI steps that discover trends and generate structured blog content.

  1. In Discover Trending Topics, keep the provided message prompt as-is to return clean JSON.
  2. In Create Content & Image Prompt, set Model to sonar-pro and keep the message template with {{ $json.Topic }} and {{ $json.row_number }}.
  3. Credential Required: Connect your Perplexity credentials in Discover Trending Topics and Create Content & Image Prompt.

Step 4: Configure Processing Logic

These code nodes clean and structure the AI outputs for reliable downstream use.

  1. Keep the JavaScript in Pick Clean Trend unchanged to randomly select a trend from search_results.
  2. Ensure Convert Text to JSON parses the AI response with return parseJSONString($input.first().json.choices[0].message.content);.
  3. Connect the flow: Discover Trending TopicsPick Clean TrendAppend Topic to SheetsRetrieve Pending TopicsCreate Content & Image PromptConvert Text to JSON.

Tip: If the AI ever wraps JSON in code fences, Convert Text to JSON removes them automatically.

Step 5: Configure WordPress Draft and Media Upload

Create a draft post and attach an AI-generated featured image via HTTP requests to WordPress.

  1. In Generate WordPress Draft, set Title to {{ $json.title }} and Content to {{ $json.content }}; keep Status as draft and Author ID as 4.
  2. Credential Required: Connect your WordPress credentials in Generate WordPress Draft.
  3. In Produce Featured Image, set URL to https://router.huggingface.co/hf-inference/models/black-forest-labs/FLUX.1-schnell and keep the JSON body { "inputs": "{{ $('Convert Text to JSON').item.json.data.image_prompt }}" }.
  4. Replace the Authorization header value in Produce Featured Image with your token: Bearer [CONFIGURE_YOUR_TOKEN].
  5. Keep Fix Image Filename unchanged to set generated-image.jpg with image/jpeg metadata.
  6. In Upload Image to WP Media, set URL to https://your-site.com/wp-json/wp/v2/media and keep Authentication as predefinedCredentialType with Credential Type wordpressApi.
  7. In Set Featured Media on Post, set URL to https://your-site.com/wp-json/wp/v2/posts/{{ $('Generate WordPress Draft').item.json.id }} and keep JSON body { "featured_media": {{ $json.id }} }.
  8. Credential Required: Connect your WordPress API credentials in Upload Image to WP Media and Set Featured Media on Post.

⚠️ Common Pitfall: If you leave https://your-site.com unchanged, media upload and featured image assignment will fail.

Step 6: Test and Activate Your Workflow

Run a full test to confirm data flows from trend discovery to WordPress draft creation.

  1. Click Execute Workflow starting from Manual Workflow Launch.
  2. Verify that Append Topic to Sheets adds a new row with is_generated set to 0.
  3. Confirm Update Sheet with Content updates the same row using the row_number match.
  4. Check WordPress for a new draft created by Generate WordPress Draft and a featured image set by Set Featured Media on Post.
  5. Once validated, toggle the workflow to Active for production use.
🔒

Unlock Full Step-by-Step Guide

Get the complete implementation guide + downloadable template

Common Gotchas

  • Google Sheets credentials can expire or need specific permissions. If things break, check the connected Google account and the n8n credential permissions 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.
  • WordPress REST API calls often fail because the user role can’t upload media. Confirm your WordPress user (the authorId you set) has Media upload permissions and that application passwords are enabled.

Frequently Asked Questions

How long does it take to set up this Sheets WordPress drafts automation?

About an hour if you already have the accounts and tokens.

Do I need coding skills to automate Sheets WordPress drafts?

No. You’ll mostly paste credentials and update a few values like your sheet ID and WordPress author ID.

Is n8n free to use for this Sheets WordPress drafts 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 Perplexity API usage and HuggingFace image generation costs.

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 customize this Sheets WordPress drafts automation for a different content format?

Yes, but expect a little tweaking. The easiest place to change format is the Perplexity “Create Content & Image Prompt” step, because that’s where the structure (headings, sections, keywords, meta) is defined. You can also adjust the “Convert Text to JSON” logic if you add new fields like category, slug, or internal links. Common customizations are swapping “developer/security” for your niche, changing the section template, and writing a stricter image prompt so featured images match your brand.

Why is my WordPress connection failing in this Sheets WordPress drafts workflow?

Usually it’s an application password issue or the user doesn’t have permission to create posts or upload media. Regenerate your WordPress application password, update the credentials in n8n, and double-check the authorId points to a real user. If drafts create fine but images fail, it’s almost always a Media upload permission or a security plugin blocking REST requests.

How many drafts can this Sheets WordPress drafts automation handle?

If you self-host n8n, it mostly depends on your server and the API rate limits. On n8n Cloud, your cap depends on the plan’s monthly executions, so high-volume sites usually move up a tier. In practice, many teams run this in batches of 5–20 topics so Sheets stays clean and WordPress doesn’t fill up with low-priority drafts. If you’re generating lots of posts daily, watch Perplexity and HuggingFace limits first.

Is this Sheets WordPress drafts automation better than using Zapier or Make?

Often, yes. This workflow needs branching logic (only generate for pending rows), structured transformations (turn AI text into JSON fields), and multi-step media handling with the WordPress REST API, and those pieces can get awkward or expensive in simpler tools. n8n also gives you the self-hosted option, which matters once you’re doing lots of drafts. Zapier or Make can still be fine for a lightweight “Sheet row → create draft” flow, just not as comfortable for end-to-end content plus images. If you want help choosing, Talk to an automation expert.

Set this up once, and your backlog turns into drafts that are actually ready to review. The workflow handles the repetitive stuff. You handle the judgment calls.

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