See llms.txt for all machine-readable content.

Back to Templates

Chase UK late invoice payments with Data Tables, GOV.UK and SMTP email

Quick overview

This workflow runs on UK working days to chase overdue B2B invoices stored in an n8n Data Table, calculates statutory late-payment interest using Bank of England base rates and UK bank holidays from GOV.UK, and drafts or sends escalating reminder emails while logging the outcome back to the table.

How it works

  1. Runs manually or every weekday at 09:00 (Europe/London) and loads configurable business, email, and escalation settings.
  2. Fetches UK bank holidays from GOV.UK and Bank of England base-rate history (using a fallback rate if the feed is unavailable).
  3. Creates the late_payment_invoices n8n Data Table if missing and optionally inserts demo invoice rows when the table is empty.
  4. Loads all invoices and determines which are overdue and eligible, skipping paid, not-yet-due, disputed, non-business, or invalid records.
  5. Calculates days overdue, the applicable statutory or contract interest rate, interest to date, fixed compensation (where applicable), and the next reminder level.
  6. For invoices that need a new reminder level, composes a friendly/second/final reminder message and either sends it via SMTP or saves it as a draft based on send_mode.
  7. Updates the Data Table with the reminder content, calculated amounts, reminder level, and a status note for sent, drafted, failed, or skipped items.

Setup

  1. Update the values in Config (business name, sender name, from address, payment instructions, escalation day thresholds, and UK bank-holiday division).
  2. Run the workflow once to create the late_payment_invoices Data Table, review the demo drafts, then replace demo rows with your real invoices and set load_demo_data to false.
  3. If you want to send emails, add SMTP credentials for the Email Send node and change send_mode from draft to send after testing with your own address.