Automated MySQL to Google Sheets Sync with Duplicate Prevention
📝 Sync MySQL Rows to Google Sheet
Description:
This n8n template automates the process of syncing new records from a MySQL database table into a Google Sheet, ideal for reporting, backup, or lightweight dashboards.
It is designed for teams or individuals who need to periodically export new data rows from a custom database (e.g., CRM, registrations, surveys) into a structured Google Sheet for further analysis, sharing, or archiving—without duplicates.
🛠️ What This Workflow Does:
Runs every 15 minutes** via a schedule trigger. Selects unsynced rows** (sync = 0) from a MySQL table (fifa25_customers). Checks if records exist** to prevent unnecessary writes. Appends records to a Google Sheet**, mapping fields like name, email, phone, gender, and more. Updates the MySQL table** to mark those rows as synced (sync = 1) to avoid reprocessing. Fully annotated using sticky notes for easier understanding and onboarding.
📋 Setup Instructions:
Create or select a Google Sheet and make sure the columns match the following:
id, name, phone, birthdate, email, region, gender, datatime Ensure your MySQL table (fifa25_customers) has a sync column (default = 0 for new rows). Connect your MySQL and Google Sheets credentials inside n8n. (Optional): Add custom filtering or column transformations as needed.
👤 Who Is It For?
Marketers syncing leads to a spreadsheet Ops teams pulling user data from internal tools Analysts logging form submissions or customer data Anyone needing lightweight scheduled ETL from MySQL to Sheets
🔐 Credentials Required:
MySQL** Google Sheets OAuth2**
✅ Best Practices Followed:
Uses IF node to prevent unnecessary processing Updates source database to avoid duplicates Includes sticky notes for clarity All columns are explicitly mapped Works out-of-the-box on any n8n instance with proper creds
Related Templates
Demo Workflow - How to use workflowStaticData()
This workflow demonstrates how to use the workflowStaticData() function to set any type of variable that will persist wi...
Bulk Automated Google Drive Files Sharing and Direct Download Link Generation
This N8N workflow automates the process of sharing files from Google Drive. It includes OAuth2 authentication, batch pro...
USDT And TRC20 Wallet Tracker API Workflow for n8n
Overview This n8n workflow is specifically designed to monitor USDT TRC20 transactions within a specified wallet. It u...
🔒 Please log in to import templates to n8n and favorite templates
Workflow Visualization
Loading...
Preparing workflow renderer
Comments (0)
Login to post comments