Automated Client Invoicing and Payment Reminder System - n8n Workflow

Use this robust n8n workflow to automate monthly invoice creation using Google Sheets and manage collections by sending escalating email payment reminders. Easily deploy this n8n template for finance automation.

Workflow Preview

Ready to automate?

Download this n8n workflow template and start using it instantly.

Who is this best for?

This is the ideal n8n template for:
Small business owners and freelancers seeking to automate billing.
Finance teams looking for a centralized, low-code collections system.
Users who want a practical example of a complex, scheduled n8n workflow combining logic and external services.
Anyone needing robust n8n automation for Google Sheets and email.

Overview

Managing monthly billing and chasing overdue payments manually is time-consuming and prone to errors. This powerful n8n workflow solves this by running two independent, scheduled automations: one for invoice generation and one for collections. Utilizing the scheduling capabilities of the n8n trigger and sophisticated custom code logic, this solution ensures active clients are billed on time and overdue accounts receive timely, escalating reminders (Gentle, Follow-up, Urgent, Final Notice). This comprehensive n8n node setup provides a complete, hands-off billing cycle management system, making it one of the most useful n8n templates for financial operations.

How it Works

This n8n workflow is divided into two main, independently scheduled processes:

1. Invoice Creation Flow (Monthly)


  1. The Monthly Invoice Trigger n8n node (a Cron node) initiates the flow on a set schedule.

  2. The workflow reads all client data using the Get Clients for Invoicing Google Sheets n8n node.

  3. The Filter Active Clients Code n8n node processes this data, filtering only clients marked 'active' and whose billing date is due.

  4. The Generate Invoice Data Code n8n node creates a unique invoice number, determines the current date as the issue date, and calculates a 30-day due date.

  5. The Save Invoice to Google Sheets n8n node appends the newly created invoice record to the 'Invoices' sheet.

  6. The Send Invoice Email n8n node immediately sends the invoice details to the client using SMTP.

  7. Finally, the Log Invoice Creation Google Sheets n8n node records the activity in a separate log sheet for auditing.

2. Payment Reminder Flow (Daily)


  1. The Daily Payment Reminder Check n8n trigger starts every day.

  2. The Get Overdue Invoices Google Sheets n8n node retrieves all records from the 'Invoices' sheet.

  3. The Filter Overdue Invoices Code n8n node checks the 'status' and 'due date' columns to isolate only unpaid invoices that are past due.

  4. The Calculate Reminder Type Code n8n node calculates the number of days overdue and assigns a severity label (e.g., 'gentle' for 1 day overdue, 'final' for 30+ days overdue).

  5. The Switch Reminder Type n8n node routes the execution based on the severity calculated in the previous step.

  6. The appropriate email n8n node (Send Gentle Reminder, Send Follow-up Reminder, etc.) sends the customized message to the client, using the dynamically generated subject line.

  7. The Update Reminder Log Google Sheets n8n node updates the original invoice record to increment the reminder count and log the date the last reminder was sent.

Installation Guide

To deploy this comprehensive n8n template, follow these steps:


  1. Import the Workflow: Copy the provided JSON data and paste it into your n8n instance via the 'New' menu -> 'Import from JSON'.

  2. Google Sheets Setup: You will need two sheets linked via the same Google API Service Account credential:

Clients: Must contain columns (A-G) for clientid, clientname, email, servicedescription, billingdate, status, and amount.
Invoices: Must contain columns for tracking the invoice details, status, and reminder logs.
ActivityLog (Optional but recommended): For auditing.

  1. Update Google Sheet IDs: In the parameters of the Get Clients for Invoicing, Get Overdue Invoices, Save Invoice to Google Sheets, and Log Invoice Creation nodes, replace YOURGOOGLESHEETID with the actual ID of your spreadsheet.

  2. Credential Configuration:

Google Sheets: Set up a Google Service Account credential and apply it to all Google Sheets n8n node instances.
* SMTP: Configure an SMTP or Gmail n8n node credential (as used by Send Invoice Email and reminder nodes) to handle outgoing messages. Ensure fromEmail addresses are correct.

  1. Activate: Once credentials and sheet IDs are configured, activate the main n8n workflow. The n8n trigger nodes will begin operating on their set schedules.

Node Details

Monthly Invoice Trigger / Daily Payment Reminder Check (Cron n8n trigger node): Initiates the two main branches of the n8n workflow based on configured schedules (monthly for billing, daily for reminders).
Google Sheets n8n node (Multiple Instances): Used extensively for reading client lists (Get Clients), reading and updating invoice records (Get Overdue Invoices, Save Invoice), and logging activity. Authentication is set to serviceAccount.
Code n8n node (Filter Active Clients / Filter Overdue Invoices): Contains custom JavaScript logic crucial for filtering the raw sheet data. The invoice filter checks client status ('active') and billing dates, while the reminder filter checks invoice status ('pending') and due dates.
Code n8n node (Generate Invoice Data): Dynamically constructs essential invoice metadata, including a unique invoice number and calculated due date (30 days out), before saving the data.
Code n8n node (Calculate Reminder Type): Calculates the precise number of days an invoice is overdue and categorizes the necessary email response (e.g., 'gentle', 'urgent', 'final') to feed the subsequent n8n node.
Switch n8n node: A core logic flow control n8n node that directs the data item to one of four specific email paths based on the reminder_type calculated in the previous step.


  • EmailSend n8n node (Multiple Instances): Used for sending the initial invoice and the four levels of payment reminders. It uses expression logic (e.g., ={{ $json.email }}) to dynamically insert client emails and customized subject lines generated by the logic nodes.

Related n8n Workflows

Free

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

The AI Squad Initiative is a pioneering effort to build, automate and scale AI-powered workflows using n8n.io. Our mission is to help individuals and businesses integrate AI agents seamlessly into their daily operations from automating tasks and enhancing productivity to creating innovative, intelligent solutions. We design modular, reusable AI workflow templates that empower creators, developers and teams to supercharge their automation with minimal effort and maximum impact.

Featured*