AI-Powered WooCommerce SEO Meta Tag Generation using Yoast - n8n Workflow

Use this sophisticated n8n workflow to automatically generate SEO-optimized meta titles and descriptions for WooCommerce products using AI (Gemini) and update them via Yoast.

Workflow Preview

Ready to automate?

Download this n8n workflow template and start using it instantly.

Who is this best for?

E-commerce managers using WooCommerce who need bulk SEO optimization.
SEO specialists looking to scale meta tag creation efficiently.
Users seeking advanced n8n templates integrating AI and core e-commerce platforms.
Automation enthusiasts interested in sophisticated LangChain n8n node setups.


  • Developers looking for practical examples of the WooCommerce n8n node and Google Sheets n8n node integration.

Overview

Writing unique, high-quality meta titles and descriptions for hundreds or thousands of products is a massive time sink for e-commerce teams. This powerful n8n workflow solves this problem by creating an automated, scalable SEO optimization pipeline.

It establishes a queue in Google Sheets, pulls unprocessed product data from WooCommerce, uses a specialized AI expert prompt within a LangChain n8n node setup (powered by Gemini 2.0 via OpenRouter) to generate compelling meta tags, and then seamlessly pushes these updates directly into the WooCommerce product metadata fields recognized by the Yoast SEO plugin.

Implementing this advanced n8n automation ensures consistent, optimized SEO quality across your entire product catalog, making this a highly valuable addition to your library of n8n templates.

How it Works

The process is initiated by an n8n trigger, which can be the Schedule Trigger for continuous operation or the manual testing n8n node. The flow begins with the Get product ID Google Sheets n8n node, which queries a predefined spreadsheet, acting as a queue, to find the next product lacking a meta title for processing.

Next, the Get product WooCommerce n8n node uses the retrieved ID to fetch the comprehensive product details (including title, description, and categories). This raw data is passed to the Generate metatitle e metadescription LangChain n8n node. This specific n8n node utilizes a detailed SEO prompt, instructing the AI (connected via the Gemini 2.0 Flash Exp OpenRouter n8n node) to adhere strictly to character limits (60/160) and optimization criteria.

Crucially, the Structured Output Parser n8n node validates the AI's output, ensuring the generated metatitle and metadescription are correctly structured for subsequent steps. The Update product WooCommerce n8n node then executes the core action, updating the product using the specific Yoast SEO metadata keys (yoastwpseotitle and yoastwpseometadesc). Finally, the Update Sheet Google Sheets n8n node marks the processed row in the queue with the new meta tags and a timestamp, completing one cycle of the n8n workflow.

Installation Guide

To deploy this n8n workflow, follow these steps:


  1. Import: Copy the provided JSON data and paste it directly into your n8n instance to create a new n8n workflow.

  2. Google Sheets Setup: Create a copy of the required Google Sheet (referenced in the sticky note). Ensure the columns match the workflow's expectations (e.g., ID POST, METATITLE, METADESCRIPTION).

  3. Credentials - Google Sheets: Configure the Google Sheets account credential for the Google Sheets n8n node to allow read/write access to your document.

  4. Credentials - WooCommerce: Set up the WooCommerce API credential for both WooCommerce n8n node instances. This requires your store URL, Consumer Key, and Consumer Secret. Ensure this key has sufficient permissions to read products and update metadata.

  5. Credentials - AI/OpenRouter: Configure the OpenRouter credential to connect the Gemini 2.0 Flash Exp n8n node. While the Gemini 2.0 Flash Exp model is often free on this platform, an API key is required to use the LangChain n8n node for AI generation.

  6. Activate: Once all credentials are set and the Google Sheets n8n node parameters (Document ID) are configured, activate the n8n workflow using the Schedule Trigger or run a test using the Manual Trigger n8n node.

Node Details

Schedule Trigger / Manual Trigger n8n Trigger: Starts the n8n workflow on a schedule (e.g., every minute) or manually for testing. This is the entry point for the entire n8n automation.
Google Sheets (Get product ID) n8n Node: Reads the spreadsheet queue, specifically filtering for rows where the METATITLE column is empty. Retrieves the necessary 'ID POST' for the next step.
WooCommerce (Get product) n8n Node: Fetches the full product details using the product ID. This supplies the raw text content (title, description) needed by the AI.
Generate metatitle e metadescription (LangChain Chain LLM) n8n Node: The core AI logic. This n8n node sends product data, combined with a highly specific SEO expert prompt, to the language model to generate optimized meta tags.
Gemini 2.0 Flash Exp (OpenRouter) n8n Node: The specific LLM used for generation. It provides the computational engine for the LangChain n8n node, allowing for powerful AI capabilities within the n8n workflow.
Structured Output Parser (LangChain) n8n Node: Ensures the AI's free-form text output is converted into a reliable JSON object containing metatitle and metadescription keys, guaranteeing downstream compatibility.
WooCommerce (Update product) n8n Node: Updates the target product on the WooCommerce store. It uses expression linking to insert the generated meta tags into the Yoast SEO metadata fields: yoastwpseotitle and yoastwpseometadesc.
Google Sheets (Update Sheet) n8n Node: Records the completion of the task by updating the corresponding row with the new meta tags, URL, and timestamp, effectively removing the item from the processing queue.

Related n8n Workflows

Free

Nodes: 8 Nodes
Updated: December 26 2025
View all
Created by

Full-stack Web Developer based in Italy specialising in Marketing & AI-powered automations. For business enquiries, send me an email at [email protected] or add me on Linkedin.com/in/davideboizza

Featured*