Automate Visual Regression Testing with n8n & Google Gemini

This workflow solves the tedious task of manually comparing website screenshots for visual defects by automating visual regression testing using Apify screenshots, Google Gemini vision AI, Google Sheets, and Linear. Save hours in QA by detecting UI changes automatically.
Google Sheets
Langchain - Chain LLM
Google Drive
+10
Workflow Identifier: 1152
NODES in Use: Google Sheets, Google Drive, HTTP Request, Linear, Schedule Trigger, SplitInBatches, Wait, Merge, Filter, Sticky Note, Langchain – Chain LLM, Langchain – Chat Model, Langchain – Structured Output Parser

Press CTRL+F5 if the workflow didn't load.

Learn how to Build this Workflow with AI:

Visit through Desktop for Best experience

What This Workflow Does

This workflow checks if websites look different from one week to next by taking two pictures and comparing them using an AI.
It finds differences in text, pictures, colors, and layout changes.
Then it puts all found changes in an issue tracking tool for fixing.
This saves time and avoids human mistakes in checking website look after updates.


Who Should Use This Workflow

If you check visual website changes often and spend too much time on it, this workflow is for you.
It helps teams who want fast and correct results when confirming no visual bugs reach their users.


Tools and Services Used

  • Google Sheets: Holds list of webpages and image links.
  • Google Drive: Stores the screenshots safely.
  • Apify.com: Takes webpage screenshots automatically.
  • Google Gemini (PaLM) API: Uses AI to spot visual differences in screenshots.
  • Linear.app: Creates issues for developers to fix found problems.
  • n8n Automation Platform: Runs all steps in one workflow.

Inputs, Processing Steps, and Output

Inputs:

  • Google Sheets webpage list with URLs and old screenshot references.
  • API keys for Apify, Google services, Linear, and Google Gemini.

Processing Steps:

  • Pull URLs from Google Sheets.
  • Take baseline screenshots of each webpage using Apify API.
  • Download baseline images and upload them to Google Drive.
  • Update Google Sheets with new Google Drive file IDs.
  • Schedule weekly runs.
  • Take new screenshots each week using Apify.
  • Download new screenshots temporarily.
  • Match baseline and new images per URL.
  • Send paired images to Google Gemini AI for visual difference detection.
  • Parse AI results to identify exact changed parts and descriptions.
  • Filter out pages without changes.
  • Group all detected changes in one dataset.
  • Create a detailed issue in Linear.app with found visual bugs.

Output:

An issue report listing all visual differences per tested webpage.
It helps developers quickly see and fix UI problems.


Beginner Step-by-Step: How to Use This Workflow in n8n

Step 1: Import Workflow

  1. Download the workflow file using the Download button on this page.
  2. Open n8n editor.
  3. Use the Import from File option to upload the workflow file.

Step 2: Configure Credentials

  1. Add API keys and login details for Google Sheets, Google Drive, Apify, Google Gemini, and Linear into n8n credentials.
  2. Make sure the credentials have proper access to needed services.

Step 3: Update IDs and Details

  1. Check and replace any Google Drive folder IDs, Google Sheets document URLs, Linear workspace IDs, or emails to your own.
  2. Copy paste prompt text for the AI node from workflow description if needed.

Step 4: Test the Workflow

  1. Run the workflow once manually inside n8n editor to check for errors.
  2. Fix any credential or permission errors that occur.

Step 5: Activate for Production

  1. Turn on the Schedule Trigger node to start weekly automatic runs.
  2. Monitor executions for any issues and set notifications as needed.
  3. If using self hosting n8n, see self-host n8n for help.

Customization Ideas

  • Change screenshot service by updating Apify API node to other providers.
  • Replace Google Gemini AI node with other vision models supported by Langchain if preferred.
  • Switch Linear issue creation to JIRA or Slack messages depending on team tools.
  • Modify schedule trigger timing for daily, monthly, or custom test intervals.

Common Problems and Fixes

  • API rate limit error: Happens if Apify API gets too many rapid requests.
    Fix: Add delay node or get higher API plan.
  • Google Sheets update fails: Happens if Google credentials lack permission.
    Fix: Re-login Google accounts and check folder plus sheet permissions.
  • AI output empty or invalid: Occurs when AI prompt or output format is wrong.
    Fix: Adjust AI prompt and JSON schema, test with sample images.

Pre-Production Checklist

  • Confirm Google Sheets has URLs and old image IDs filled.
  • Validate all API credentials and permissions are correct.
  • Test Apify screenshot calls in HTTP Request nodes manually.
  • Run single workflow execution to check image saving and Google Sheets update.
  • Review AI response format with some test images to ensure correct parsing.

Summary of Workflow Benefits and Outcome

✓ Automates visual testing of multiple client websites weekly.
✓ Saves about 6+ hours of manual checking every week.
✓ Detects detailed changes in text, images, colors, and layout.
✓ Creates clear issue reports for developers to act quickly.
✓ Improves QA accuracy by reducing human errors.
✓ Integrates Google Sheets, Drive, Apify, Google Gemini AI, Linear, within n8n.
→ Provides a ready-to-go visual regression testing automation system.


Frequently Asked Questions

It solves the problem of manually checking website visuals by automatically detecting differences between website screenshots using AI.
It needs Google Sheets, Google Drive, Apify.com, Google Gemini (PaLM) API, Linear.app, and n8n automation platform.
A beginner can download the workflow file, import it into n8n, add all required API keys and IDs, test once, then activate the schedule trigger for production.
Errors from AI output happen due to wrong prompts or schema. Fix by adjusting the AI prompt and output JSON schema and testing with sample images.

Promoted by BULDRR AI

Related Workflows

Automate Viral UGC Video Creation Using n8n + Degaus (Beginner-Friendly Guide)

Learn how to automate viral UGC video creation using n8n, AI prompts, and Degaus. This beginner-friendly guide shows how to import, configure, and run the workflow without technical complexity.
Form Trigger
Google Sheets
Gmail
+37
Free

AI SEO Blog Writer Automation Workflows in n8n

A complete beginner guide to building an AI SEO blog writer automation using n8n.
AI Agent
Google Sheets
httpRequest
+5
Free

Automate CrowdStrike Alerts with VirusTotal, Jira & Slack

This workflow automates processing of CrowdStrike detections by enriching threat data via VirusTotal, creating Jira tickets for incident tracking, and notifying teams on Slack for quick response. Save hours daily by transforming complex threat data into actionable alerts effortlessly.
scheduleTrigger
httpRequest
jira
+5
Free

Automate Telegram Invoices to Notion with AI Summaries & Reports

Save hours on financial tracking by automating invoice extraction from Telegram photos to Notion using Google Gemini AI. This workflow extracts data, records transactions, and generates detailed spending reports with charts sent on schedule via Telegram.
lmChatGoogleGemini
telegramTrigger
notion
+9
Free

Automate Email Replies with n8n and AI-Powered Summarization

Save hours managing your inbox with this n8n workflow that uses IMAP email triggers, AI summarization, and vector search to draft concise replies requiring minimal review. Automate business email processing efficiently with AI guidance and Gmail integration.
emailReadImap
vectorStoreQdrant
emailSend
+12
Free

Automate Email Campaigns Using n8n with Gmail & Google Sheets

This n8n workflow automates personalized email outreach campaigns by integrating Gmail and Google Sheets, saving hours of manual follow-up work and reducing errors in email sequences. It ensures timely follow-ups based on previous email interactions, optimizing communication efficiency.
googleSheets
gmail
code
+5
Free