🔓 Unlock all 10,000+ workflows & prompts free Join Newsletter →
✅ Full access unlocked — explore all 10,000 AI workflow and prompt templates Browse Templates →
Home n8n Workflow
January 22, 2026

Smartlead to Google Sheets, always fresh campaign stats

Lisa Granqvist Partner Workflow Automation Expert

Your Smartlead stats are “somewhere in the platform,” your report is “somewhere in a sheet,” and your team is “somewhere” making decisions off last week’s numbers. That’s the real problem. Exports get forgotten, tabs drift out of sync, and one wrong copy‑paste turns a clean report into a small disaster.

Marketing ops folks get stuck maintaining the spreadsheet instead of improving campaigns. A sales lead wants fast visibility into replies and bounces. And a busy founder just wants a single source of truth. This Smartlead Sheets sync automation keeps campaign stats fresh without babysitting.

Below you’ll see how the workflow runs on a schedule, pulls lead-level engagement (opens, clicks, replies, unsubscribes, bounces), and upserts it into Google Sheets with no duplicates.

How This Automation Works

The full n8n workflow, from trigger to final output:

n8n Workflow Template: Smartlead to Google Sheets, always fresh campaign stats

The Problem: Campaign stats go stale (and nobody notices)

Email campaigns move quickly. Replies come in, bounces spike, a subject line starts winning, and suddenly yesterday’s “best lead list” is wrong. But the reporting process usually looks like this: someone exports from Smartlead, pastes into Google Sheets, fixes columns, removes duplicates, and hopes nobody asks for an update tomorrow. It’s not just the time. It’s the constant uncertainty because you’re never totally sure the sheet reflects reality.

The friction compounds. Here’s where things typically break down.

  • Manual exports slip, so weekly reporting turns into “whenever someone remembers.”
  • Rows get duplicated because the same lead shows up in multiple pulls, which wrecks pivot tables.
  • Teams spend about 2 hours per week reconciling “whose numbers are right.”
  • By the time you spot a bounce or unsubscribe trend, you’ve already sent the next batch.

The Solution: Scheduled Smartlead stats synced into Google Sheets

This workflow turns Smartlead campaign analytics into an always-updated Google Sheet you can trust. It starts on a schedule (hourly, every 2 hours, daily, whatever fits), generates pagination batches so it can safely pull thousands of records, and calls Smartlead’s campaign statistics endpoint using your API key and campaign ID. The response comes back as an array of lead-level engagement records, which the workflow expands into one row per lead-stat item. Then it writes into Google Sheets using an “append or update” action keyed on stats_id, so the same record updates in place instead of creating duplicates.

The workflow starts with a Schedule Trigger, then uses a small code step to emit {offset, limit} pairs. Smartlead data is fetched batch-by-batch, split into individual lead records, and upserted into an EngagedLeads tab in Google Sheets. Once the sheet is stable, you can build dashboards, pivots, or even connect it to BI tools without constantly cleaning the data.

What You Get: Automation vs. Results

Example: What This Looks Like

Say you run one Smartlead campaign with about 1,000 leads and you refresh reporting twice a day. Manually, that’s usually 15 minutes to export, 20 minutes to clean and dedupe, and another 10 minutes to fix dashboards, so about 45 minutes per refresh. That’s roughly 1.5 hours a day. With this workflow, you set a schedule, the API pulls and upserts automatically, and your “work” becomes a quick spot-check in Sheets (maybe 5 minutes).

What You’ll Need

  • n8n instance (try n8n Cloud free)
  • Self-hosting option if you prefer (Hostinger works well)
  • Smartlead for campaign statistics and engagement events
  • Google Sheets to store and share the live dataset
  • Smartlead API key (get it from your Smartlead account settings)

Skill level: Beginner. You’ll connect accounts, paste an API key, and match sheet columns.

Don’t want to set this up yourself? Talk to an automation expert (free 15-minute consultation).

How It Works

A schedule kicks things off. You choose the cadence (hourly, every 2 hours, daily). That trigger starts the run automatically, so your reporting stays fresh even when nobody’s thinking about it.

Pagination batches are generated. A small code step outputs offset/limit pairs (for example, 0–9,900 in steps of 100). This matters because Smartlead can return lots of records, and pulling them in chunks is safer and more reliable.

Smartlead stats are fetched and expanded. n8n loops through each batch, calls Smartlead’s campaign statistics endpoint via HTTP Request, then turns the returned data[] array into one item per lead record. Clean input equals clean Sheets rows.

Google Sheets is updated without duplicates. The workflow uses an append-or-update operation keyed on stats_id, writing into your EngagedLeads tab. If the same record comes back next run, it updates the existing row instead of creating a mess.

You can easily modify the schedule frequency to match your reporting rhythm based on your needs. See the full implementation guide below for customization options.

Step-by-Step Implementation Guide

Step 1: Configure the Schedule Trigger

Set the workflow to run on a recurring schedule using the built-in trigger.

  1. Add and open Scheduled Automation Kickoff.
  2. In Rule, set the interval Field to hours.
  3. Connect Scheduled Automation Kickoff to Generate Pagination Batches as the first step in the flow.

Step 2: Connect Google Sheets

Prepare the destination spreadsheet and connect the Google Sheets integration used for syncing campaign analytics.

  1. Open Update Spreadsheet Rows.
  2. Credential Required: Connect your Google Sheets credentials.
  3. Set Document to [YOUR_ID] and Sheet Name to [YOUR_ID] (from the node’s list selection).
  4. Confirm Operation is appendOrUpdate and Use Append is enabled.
  5. Verify the Matching Columns include stats_id to prevent duplicates.

⚠️ Common Pitfall: The Google Sheets node has no credentials configured in the workflow. If you skip adding credentials, the node will fail at runtime.

Step 3: Set Up Pagination and Batch Processing

Create pagination payloads and loop through them so each API request retrieves a batch of records.

  1. Open Generate Pagination Batches and keep the JavaScript code as provided.
  2. If needed, adjust times and limit in the code (e.g., const times = 100; and const limit = 100;).
  3. Connect Generate Pagination Batches to Iterate Batch Items to begin the loop.
  4. Ensure Update Spreadsheet Rows connects back to Iterate Batch Items to continue batching.

Tip: Use smaller limit values if the API has rate limits or if responses are large.

Step 4: Configure Output/Action Nodes

Pull campaign analytics from the external API, split the records, and write them into Google Sheets.

  1. Open External Campaign Request and set URL to =https://server.smartlead.ai/api/v1/campaigns/[YOUR_ID]/statistics?.
  2. In Query Parameters, set api_key to [CONFIGURE_YOUR_API_KEY], offset to {{ $json.offset }}, and limit to {{ $json.limit }}.
  3. Connect Iterate Batch Items (batch output) to External Campaign Request.
  4. Open Expand Data Records and set Field to Split Out to data.
  5. Confirm Update Spreadsheet Rows has column mappings using expressions like {{ $json.stats_id }}, {{ $json.lead_email }}, and {{ $json.open_time }}.
  6. Connect External Campaign RequestExpand Data RecordsUpdate Spreadsheet Rows in sequence.

Step 5: Test and Activate Your Workflow

Run a manual test to verify batching, API responses, and Google Sheets updates before turning on the schedule.

  1. Click Execute Workflow and monitor each node’s output in order: Scheduled Automation KickoffGenerate Pagination BatchesIterate Batch ItemsExternal Campaign RequestExpand Data RecordsUpdate Spreadsheet Rows.
  2. Confirm a successful run by checking new or updated rows in the target Google Sheet using the stats_id match.
  3. Fix any API errors by validating the [YOUR_ID] in the URL and [CONFIGURE_YOUR_API_KEY] parameter.
  4. Activate the workflow by switching it to Active once the test results are correct.
🔒

Unlock Full Step-by-Step Guide

Get the complete implementation guide + downloadable template

Common Gotchas

  • Smartlead credentials can expire or need specific permissions. If things break, check your Smartlead API key validity in your Smartlead settings first.
  • If you’re using Wait nodes or external rendering, processing times vary. Bump up the wait duration if downstream nodes fail on empty responses.
  • Google Sheets “appendOrUpdate” depends on exact headers and matching column setup. If you see duplicates, confirm the matching column is stats_id and that your header names match exactly.

Frequently Asked Questions

How long does it take to set up this Smartlead Sheets sync automation?

About 30 minutes if your Smartlead API key and Google access are ready.

Do I need coding skills to automate Smartlead Sheets sync?

No. You’ll mostly connect accounts and map columns in Google Sheets.

Is n8n free to use for this Smartlead Sheets sync workflow?

Yes. n8n has a free self-hosted option and a free trial on n8n Cloud. Cloud plans start at $20/month for higher volume. You’ll also need to factor in Smartlead API access (typically included with your Smartlead plan).

Where can I host n8n to run this automation?

Two options: n8n Cloud (managed, easiest setup) or self-hosting on a VPS. For self-hosting, Hostinger VPS is affordable and handles n8n well. Self-hosting gives you unlimited executions but requires basic server management.

Can I customize this Smartlead Sheets sync workflow for multiple campaigns?

Yes, but you’ll want to be intentional about how you separate data. Most people duplicate the workflow, swap the Smartlead campaign_id in the HTTP Request URL, and write to a different tab per campaign (or add a “campaign_name” column and keep one master table). You can also change the pagination limit if you’d rather make fewer API calls per run.

Why is my Smartlead connection failing in this workflow?

Usually it’s an invalid or expired API key, so regenerate it in Smartlead and update the credential in n8n. The next most common cause is using the wrong campaign_id in the request URL. If it fails only on larger campaigns, you may be hitting rate limits, so increase the schedule interval or reduce the batch size.

How many lead records can this Smartlead Sheets sync automation handle?

A lot. This workflow is built for pagination up to about 10,000 records per run (offset/limit batches), and you can scale beyond that by generating more offsets. On n8n Cloud, capacity depends on your plan’s execution limits, while self-hosting depends on your server size and how frequently you run it.

Is this Smartlead Sheets sync automation better than using Zapier or Make?

Often, yes, because pagination, upserts, and loop logic are straightforward in n8n and you can self-host for unlimited executions. Zapier or Make can still work if you’re pulling a small dataset, but you’ll usually end up paying more once you add multiple steps and frequent schedules. n8n also makes it easier to keep a stable “matching key” like stats_id so your sheet doesn’t duplicate records. If you’re unsure, Talk to an automation expert and map it to your volume.

Your Smartlead reporting stops being a recurring chore and becomes a living dataset. Set it once, then spend your time improving sequences instead of cleaning spreadsheets.

Need Help Setting This Up?

Our automation experts can build and customize this workflow for your specific needs. Free 15-minute consultation—no commitment required.

Lisa Granqvist

Workflow Automation Expert

Expert in workflow automation and no-code tools.

×

Use template

Get instant access to this n8n workflow Json file

💬
Get a free quote today!
Get a free quote today!

Tell us what you need and we'll get back to you within one working day.

Get a free quote today!
Get a free quote today!

Tell us what you need and we'll get back to you within one working day.

Launch login modal Launch register modal