🔓 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

WordPress + OpenAI: publish-ready posts, hands free

Lisa Granqvist Partner Workflow Automation Expert

Your content pipeline probably isn’t “hard.” It’s just annoying. Research in one tab, outlines in another, drafts in a doc, images somewhere else, then the WordPress copy-paste marathon (plus fixing headings, slugs, excerpts, featured images). That’s why WordPress OpenAI automation is suddenly on every marketer’s shortlist.

If you’re a content manager, you feel it when deadlines stack up. If you run a small business site, the blog slips because publishing is a whole project. And agency leads hit the same wall when they try to scale output without sacrificing quality.

This workflow turns a simple form submission into a research-backed, publish-ready WordPress post with images and metadata. You’ll see exactly how it works, what you need, and where people usually get stuck.

How This Automation Works

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

n8n Workflow Template: WordPress + OpenAI: publish-ready posts, hands free

Why This Matters: Publishing Bottlenecks Kill Consistency

Most teams don’t fail at content because they can’t write. They fail because shipping is slow and messy. Research takes longer than expected, drafts get stuck in review, and by the time you format everything in WordPress you’re already behind on the next post. The worst part is the mental load. You’re not just “writing,” you’re managing slugs, excerpts, categories, image sizes, media uploads, and a dozen tiny checks that only show up when something breaks on the live page. Honestly, it’s the kind of work that makes people dread publishing.

The friction compounds. Here’s where it usually breaks down.

  • You spend about 1–2 hours per post doing research, formatting, and WordPress cleanup instead of writing.
  • Images become the blocker, because sourcing, generating, naming, uploading, and embedding adds more steps than it should.
  • SEO structure ends up inconsistent, which means posts look different week to week and editing takes longer.
  • When content lives across docs, chats, and spreadsheets, you lose track of what’s drafted, reviewed, or published.

What You’ll Build: A Form-to-WordPress Publishing Machine

This n8n workflow starts with a simple form submission: you provide a topic, target audience, and industry. From there, an AI “research agent” uses web search tools (like Tavily and Perplexity) to gather context and patterns from what’s already ranking. Next, a writing agent turns that research into a full blog post with proper HTML structure for WordPress, so headings, sections, and formatting are already in place. Then it generates a featured image plus supporting images, uploads them to your WordPress media library, and embeds them into the post body. Finally, it publishes the post (or saves it as a draft), sets metadata like slug and excerpt, and assigns the featured image so the post looks complete the moment it hits your site.

The workflow begins with your content brief and ends with a real WordPress post, created via the WordPress API. In the middle, it stores intermediate drafts in an n8n data table, runs quality checks, and retries steps if an image or response isn’t ready yet.

What You’re Building

Expected Results

Say you publish 3 posts per week. Manually, a “write + format + upload images + WordPress setup” routine is often about 2 hours per post, so you’re spending roughly 6 hours a week just to get content live. With this workflow, you might spend 5 minutes filling the form and another 10–15 minutes reviewing the draft and images before you let it publish. That’s about 5 hours back most weeks, without skipping the parts that make the post look polished.

Before You Start

  • n8n instance (try n8n Cloud free)
  • Self-hosting option if you prefer (Hostinger works well)
  • WordPress for publishing posts via the API
  • OpenAI to research and write the article
  • Tavily API key (get it from tavily.com)

Skill level: Intermediate. You’ll connect credentials, edit a few URLs, and test with a sample post.

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

Step by Step

A form submission kicks things off. You enter the topic, audience, and industry, then submit. n8n captures that input and loads your saved API keys so the rest of the workflow can run unattended.

Research gets compiled before writing begins. The workflow queries web search tools and aggregates the findings, which gives the writing agent better raw material than a blank prompt. This is also where it can pull from feeds or other sources if you choose to extend it later.

The post is drafted in publishable structure. The writing agent produces HTML-ready content, then a builder step assembles sections cleanly (headings, paragraphs, and placeholders for images). A data table entry is created so you have a saved draft even if you stop before publishing.

Images are generated, uploaded, and embedded. The workflow extracts image prompts, calls an image generation service, converts files when needed, uploads media to WordPress, then injects the resulting URLs directly into the HTML.

WordPress publishes and assigns metadata. A WordPress node creates the post (draft or publish), then an API call assigns the featured image and final fields like excerpt, slug, category, author, and status.

You can easily modify the publishing status to “draft” instead of “publish” based on your needs. See the full implementation guide below for customization options.

Step-by-Step Implementation Guide

Step 1: Configure the Form Trigger

Start the workflow with a form submission that collects the content request details.

  1. Add or open Form Submission Trigger and define the form fields your users will submit (topic, keywords, sources, tone, etc.).
  2. Save the form and confirm that Form Submission Trigger is connected to Configure API Keys.
  3. Optionally keep Flowpast Branding as a reference note in the canvas.
If you change form fields later, update downstream nodes that rely on those fields to avoid missing data.

Step 2: Connect RSS Data and Normalize Inputs

Pull external sources and aggregate them before research begins.

  1. In Configure API Keys, set the API key fields you plan to use throughout the workflow (for example, keys passed from the form).
  2. Configure RSS Feed Reader to read the RSS URL(s) you want to include as sources.
  3. Ensure RSS Feed Reader flows into Aggregate Records, then into JavaScript Transform for normalization.

Step 3: Set Up the Research Agent Loop

Use the research agent to gather and validate input before writing.

  1. Open Research Agent and confirm it receives input from JavaScript Transform.
  2. Verify Research Agent outputs to Conditional Branch, which either routes to Delay Step (for retries) or to Writing Agent.
  3. Keep the loop intact: Delay Step should return to Research Agent so the agent can retry on missing research.
  4. Confirm URL Extraction Tool and Perplexity Query Tool are attached as AI tools for both Research Agent and Writing Agent.
Credential Required: Connect your OpenAI credentials for OpenAI Chat Engine 2 (used by Research Agent). For AI tools like URL Extraction Tool and Perplexity Query Tool, add credentials in the parent agents’ tool configuration, not in the tool nodes themselves.
Tavily Search Tool exists in the workflow but is not connected. Attach it to Research Agent or Writing Agent if you intend to use it.

Step 4: Configure Writing and Draft Storage

Generate the main draft content and store it for image extraction.

  1. Open Writing Agent and verify it follows Conditional Branch.
  2. Confirm the flow from Writing Agent to Branch Logic 2, which routes to Delay Step 3 (for retries) or to Store Blog Draft.
  3. Ensure Store Blog Draft connects to Image Prompt Extractor to pull image ideas from the draft.
  4. Verify Structured Result Parser is attached to Writing Agent via ai_outputParser.
Credential Required: Connect your OpenAI credentials for OpenAI Chat Engine (language model for Writing Agent) and for OpenAI Chat Engine 3 (language model for Image Prompt Extractor). Structured Result Parser uses Gemini Chat Engine 3 as its language model, so add Google Gemini credentials to Gemini Chat Engine 3 (not the parser).

Step 5: Extract Image Prompts and Batch Processing

Split the draft into image prompts and build a list for generation and embedding.

  1. Confirm Image Prompt Extractor outputs to Custom Script Step, then to Iterate Through Records.
  2. Iterate Through Records outputs to both Compile Image List and Image Name Generator in parallel.
  3. Keep Compile Image List connected to HTML Content Builder for later HTML assembly.

Step 6: Generate, Process, and Store Images

Generate images, validate them, and store usable assets for final HTML assembly.

  1. Verify Image Name Generator feeds Map Image Prompt Fields, which then calls Image Generation Call.
  2. Check that Image Generation Call goes to Image Branch Check, which routes to Retrieve Image File on success or Delay Step 4 to retry.
  3. Follow the processing chain: Retrieve Image FileConvert Image to PNGUpload Image AssetFinalize Image URLDelay Step 2Iterate Through Records.
Credential Required: If Image Generation Call, Upload Image Asset, or Assign Featured Image access authenticated endpoints, configure authentication in those nodes before running the workflow.

Step 7: Build HTML and Publish to WordPress

Compile the final HTML, store it, and publish a WordPress post with a featured image.

  1. Confirm HTML Content Builder receives the image list from Compile Image List and passes output to Embed Images in HTML.
  2. Verify Embed Images in HTML stores the final content in Store Blog Draft 2.
  3. Ensure Store Blog Draft 2 connects to Publish WordPress Post, then to Assign Featured Image.
Credential Required: Connect your WordPress credentials in Publish WordPress Post before publishing.

Step 8: Test and Activate Your Workflow

Validate the end-to-end flow, then activate the workflow for production use.

  1. Click Execute Workflow and submit a test entry in Form Submission Trigger.
  2. Confirm successful execution: Store Blog Draft and Store Blog Draft 2 should contain records, and Publish WordPress Post should create a draft or post.
  3. Verify that images were generated, processed, and embedded in the HTML output.
  4. Once verified, switch the workflow to Active to enable production runs.
🔒

Unlock Full Step-by-Step Guide

Get the complete implementation guide + downloadable template

Troubleshooting Tips

  • WordPress Application Passwords can be revoked or blocked by security plugins. If publishing fails, re-check Users → Your Profile → Application Passwords and confirm REST API access isn’t restricted.
  • If you’re using Wait nodes or external rendering, processing times vary. Bump up the wait duration if downstream nodes fail on empty responses.
  • Default 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 WordPress OpenAI automation?

About 30 minutes if your accounts and keys are ready.

Is coding required for this post publishing automation?

No. You’ll connect credentials and adjust a couple of WordPress URLs in the HTTP Request nodes.

Is n8n free to use for this WordPress OpenAI 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 OpenAI API costs plus research and image API costs (often a few cents per post, depending on length and images).

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 WordPress OpenAI automation workflow for different use cases?

Yes, and you should. You can swap the research sources by changing the Tavily Search Tool or Perplexity Query Tool nodes, and you can adjust writing style inside the Research Agent and Writing Agent prompts. Common tweaks include setting WordPress status to draft, enforcing your section template, and generating only a featured image (not in-body images) for faster turnaround.

Why is my WordPress connection failing in this workflow?

Usually it’s the Application Password or the REST API endpoint URL. Regenerate the application password, update the credential in n8n, and confirm your publish node is pointing at your real site URL. If it still fails, check for security plugins or hosting rules that block /wp-json/ requests, and make sure the user has permission to publish posts and upload media.

What volume can this WordPress OpenAI automation workflow process?

On a typical n8n Cloud plan, you can run plenty of posts per month for a small site, and self-hosting removes execution caps (your server becomes the limit). Practically, image generation and upload are the slow parts, so expect a post to take a few minutes end-to-end even when everything is working smoothly. If you batch many posts at once, plan for API rate limits and longer waits.

Is this WordPress OpenAI automation better than using Zapier or Make?

For AI-heavy publishing, n8n is usually the better fit because you can add branching logic, retries, and multi-step processing without fighting platform limits. It’s also much easier to store intermediate drafts (like an n8n data table) so you can stop at “review” instead of always publishing. Zapier and Make can still work, but they tend to get expensive once you add research, multiple AI calls, and image handling. If you’re aiming for one clean pipeline from brief to WordPress, this workflow is closer to a real system than a simple two-step integration. Talk to an automation expert if you want help picking the right stack.

Once this is running, publishing stops being a weekly scramble. The workflow handles the repetitive parts so you can focus on what actually moves the needle: topics, positioning, and a quick final review.

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