Intermediate~20 min setupProductivity & CRMVerified April 2026
Google Sheets logo
Salesforce logo

How to Export Salesforce Pipeline to Google Sheets with N8n

Query Salesforce every morning for open opportunities and write them to a Google Sheet with current pipeline data.

Steps and UI details are based on platform versions at time of writing — check each platform for the latest interface.

Best for

Teams that need daily pipeline exports with custom formatting or high-volume Salesforce data

Not ideal for

Non-technical teams who just want basic opportunity syncing without data transformation

Sync type

scheduled

Use case type

export

Real-World Example

💡

A 25-person B2B SaaS sales team uses this to populate their morning standup sheet with current quarter opportunities over $10K. Before automation, their sales ops person spent 30 minutes each morning manually exporting from Salesforce and cleaning up the data formatting. Now the VP gets clean pipeline data at 8 AM with deal velocity calculations and next action dates automatically formatted.

What Will This Cost?

Drag the slider to your expected monthly volume.

/mo
505005K50K

Each platform counts differently — Zapier: 1 task per trigger. Make: 1 operation per module per record. n8n: 1 execution per run.

Prices shown for annual billing. Based on published pricing as of April 2026.

Estimated ROI

1000

min saved/mo

$583

labor value/mo

Free

no platform cost

Based on ~2 min manual effort per operation at $35/hr fully loaded labor cost.

Implementation

Skip the setup

Import this workflow directly into n8n

Copy the pre-built n8n blueprint and paste it straight into n8n. All modules, filters, and field mappings are already configured — you just need to connect your accounts.

Before You Start

Make sure you have everything ready.

Salesforce admin access with API enabled and security token generated
Google account with Sheets access and target spreadsheet already created
N8n instance running (cloud or self-hosted) with Google and Salesforce nodes available
Basic understanding of SOQL queries to customize opportunity fields

Field Mapping

Map these fields between your apps.

FieldAPI Name
Required
Opportunity NameName
Account NameAccount.Name
Deal AmountAmount
Sales StageStageName
Close DateCloseDate
2 optional fields▸ show
Deal OwnerOwner.Name
Last ActivityLastActivityDate

Step-by-Step Setup

1

Dashboard > + > New Workflow

Create New Workflow

Start a fresh N8n workflow for your daily pipeline export. This workflow will run on a schedule and handle all the data processing.

  1. 1Click the + button in the top left of N8n dashboard
  2. 2Select 'New Workflow' from the dropdown
  3. 3Name it 'Salesforce Pipeline Export'
  4. 4Click 'Save' in the top right
What you should see: You should see an empty workflow canvas with a single 'Start' node.
2

Nodes > Trigger > Schedule Trigger

Add Schedule Trigger

Set up a cron trigger to run every morning at 8 AM. This ensures your team gets fresh pipeline data before their workday starts.

  1. 1Click the + icon next to the Start node
  2. 2Select 'Schedule Trigger' from the Trigger section
  3. 3Set Mode to 'Every X' and choose 'Day'
  4. 4Set Hour to '8' and Minute to '0'
  5. 5Click 'Execute Node' to test
What you should see: The trigger should show 'Executed successfully' with a timestamp for the next scheduled run.
Common mistake — Don't use 'Interval' mode — it starts counting from workflow activation, not a fixed time
n8n
+
click +
search apps
Google Sheets
GO
Google Sheets
Add Schedule Trigger
Google Sheets
GO
module added
3

Nodes > Regular > Salesforce

Connect Salesforce Node

Add the Salesforce node to query your CRM data. You'll authenticate and configure it to pull open opportunities.

  1. 1Click + after the Schedule Trigger
  2. 2Search for 'Salesforce' and select it
  3. 3Choose 'Search' as the operation
  4. 4Click 'Create New' next to Credentials
  5. 5Enter your Salesforce username and password plus security token
What you should see: Green checkmark next to credentials with 'Connection successful' message.
4

Salesforce Node > Parameters

Configure Opportunity Query

Set up the SOQL query to fetch open opportunities with the fields your team needs in the Google Sheet.

  1. 1Set Resource to 'Search'
  2. 2In the 'Query' field, enter: SELECT Id, Name, Amount, StageName, CloseDate, AccountId, OwnerId FROM Opportunity WHERE IsClosed = false
  3. 3Set 'Return All' to true
  4. 4Click 'Execute Node' to test the query
What you should see: You should see a list of opportunity records with fields like Name, Amount, and StageName populated.
Common mistake — Don't forget the security token — it's your password plus the token Salesforce emails you
5

Nodes > Data > Code

Add Data Processing

Transform the Salesforce data into a format Google Sheets can handle. This step cleans up field names and formats currency values.

  1. 1Click + after the Salesforce node
  2. 2Select 'Code' from the Data section
  3. 3Choose 'Run Once for All Items'
  4. 4Paste the data transformation code in the editor
  5. 5Click 'Execute Node' to see the formatted output
What you should see: The output should show clean column headers like 'Opportunity Name' instead of 'Name' and formatted amounts.
Common mistake — Set execution mode to 'Run Once for All Items' or you'll get one sheet row per opportunity instead of a batch
6

Nodes > Regular > Google Sheets

Connect Google Sheets

Authenticate with Google Sheets and prepare to write your pipeline data to the target spreadsheet.

  1. 1Click + after the Code node
  2. 2Search for 'Google Sheets' and select it
  3. 3Choose 'Append' as the operation
  4. 4Click 'Create New' next to Credentials
  5. 5Follow the OAuth flow to connect your Google account
What you should see: You should see 'Google Sheets credentials created successfully' with your email address shown.
7

Google Sheets Node > Parameters

Configure Sheet Details

Point N8n to your target Google Sheet and specify which tab to write the pipeline data to.

  1. 1Paste your Google Sheet ID from the URL
  2. 2Set 'Range' to 'Sheet1!A:H' (adjust columns as needed)
  3. 3Toggle 'Data Starts on Row 2' to true
  4. 4Set 'Value Input Mode' to 'User Entered'
  5. 5Map each field from the Code node output
What you should see: Field mappings should show Salesforce data flowing to specific columns like A=Name, B=Amount, C=Stage.
Common mistake — Use 'User Entered' mode so currency amounts format correctly — 'Raw' mode turns $50,000 into text
8

Google Sheets Node > Clear Operation

Clear Previous Data

Add a step to clear yesterday's data before appending new rows. This prevents your sheet from growing infinitely.

  1. 1Add another Google Sheets node before the append step
  2. 2Set operation to 'Clear'
  3. 3Use the same Sheet ID and credentials
  4. 4Set Range to 'Sheet1!A2:H1000'
  5. 5Connect this node between Code and the Append node
What you should see: The clear operation should show 'Range cleared successfully' when executed.
Common mistake — Don't clear row 1 if it contains your column headers — start from A2 to preserve the header row
9

Node > Right Click > Add Error Handler

Add Error Handling

Wrap critical nodes in error handling so the workflow doesn't break when Salesforce is down or rate limits hit.

  1. 1Right-click the Salesforce node
  2. 2Select 'Add Error Handler'
  3. 3Choose 'Continue on Fail' from the dropdown
  4. 4Add a 'Send Email' node to the error path
  5. 5Configure it to notify you when the export fails
What you should see: You should see a red error path branching from the Salesforce node to your notification setup.
Common mistake — Test the error path by temporarily breaking your Salesforce credentials — don't wait for a real failure to validate it works
10

Bottom toolbar > Execute Workflow

Test Complete Workflow

Run the entire workflow end-to-end to verify data flows correctly from Salesforce to your Google Sheet.

  1. 1Click 'Execute Workflow' at the bottom
  2. 2Watch each node turn green as it processes
  3. 3Check your Google Sheet for the exported opportunities
  4. 4Verify column headers and data formatting look correct
  5. 5Save the workflow when test succeeds
What you should see: Your Google Sheet should contain current open opportunities with properly formatted amounts and dates.
Common mistake — Run this test during business hours when your Salesforce instance is active — some orgs restrict API access after hours
n8n
▶ Run once
executed
Google Sheets
Salesforce
Salesforce
🔔 notification
received
11

Top right toggle > Activate

Activate Scheduled Run

Turn on the workflow so it runs automatically every morning at 8 AM without manual intervention.

  1. 1Click the toggle switch at the top right of the workflow
  2. 2Confirm the activation in the popup dialog
  3. 3Check the 'Executions' tab to see the schedule registered
  4. 4Set up webhook notifications if you want alerts on failures
What you should see: The workflow status should show 'Active' with the next execution time displayed.
Common mistake — Double-check your timezone settings — N8n uses UTC by default, so 8 AM might actually run at midnight your time

Drop this into an n8n Code node.

JavaScript — Code Node// Format currency and dates in Code node
▸ Show code
// Format currency and dates in Code node
for (const item of items) {
  item.json.Amount = item.json.Amount ? `$${Number(item.json.Amount).toLocaleString()}` : '$0';

... expand to see full code

// Format currency and dates in Code node
for (const item of items) {
  item.json.Amount = item.json.Amount ? `$${Number(item.json.Amount).toLocaleString()}` : '$0';
  item.json.CloseDate = item.json.CloseDate ? new Date(item.json.CloseDate).toLocaleDateString('en-US') : '';
  item.json.DaysToClose = item.json.CloseDate ? Math.ceil((new Date(item.json.CloseDate) - new Date()) / (1000 * 60 * 60 * 24)) : '';
}
return items;

Scaling Beyond 500+ opportunities per export+ Records

If your volume exceeds 500+ opportunities per export records, apply these adjustments.

1

Batch Google Sheets Operations

Use Google's batchUpdate API instead of individual row appends. Process opportunities in chunks of 100 using N8n's SplitInBatches node to avoid rate limits.

2

Optimize Salesforce Queries

Add WHERE filters like CreatedDate >= LAST_N_DAYS:30 to reduce query size. Use indexed fields like Id, CreatedDate, or OwnerId in your WHERE clause for faster responses.

3

Implement Incremental Sync

Track last sync time and only query modified opportunities using WHERE LastModifiedDate >= :lastSyncTime. Store the timestamp in N8n's workflow static data between runs.

Going live

Production Checklist

Before you turn this on for real, confirm each item.

Troubleshooting

Common errors and how to fix them.

Frequently Asked Questions

Common questions about this workflow.

Analysis

VerdictWhy n8n for this workflow

Use N8n for this if you need custom data transformations or run high volumes that would cost $200+/month on Zapier. N8n's code nodes let you format currency, calculate deal velocity, or merge account data without API limits. The self-hosted option means unlimited executions once you're past 20K/month. Skip N8n if your team doesn't touch code — Make's visual data mapping is cleaner for simple field copying.

Cost

This workflow uses about 15 executions per run (clear sheet, query Salesforce, process data, append rows). At daily runs, that's 450 executions monthly. N8n's Starter plan at $20/month includes 5K executions, so you're well covered. Zapier would charge $20/month just for the Salesforce premium connector, plus $50/month for the task volume. Make costs $9/month for 1K operations but charges extra for Salesforce API calls.

Tradeoffs

Make handles Google Sheets formatting better — their spreadsheet connector automatically detects currency and date columns without custom code. Zapier's Salesforce integration includes more pre-built filters like 'opportunities closing this quarter' without writing SOQL. But N8n wins on flexibility — you can add calculated fields, merge data from multiple Salesforce objects, or export to multiple sheets in one workflow without hitting connector limits.

Google Sheets API paginates at 1K rows, so exports over that size need batching logic in your Code node. Salesforce query limits hit at 50K records per call — add LIMIT and OFFSET clauses if your pipeline exceeds that. The Sheets clear operation is slow on large ranges, taking 10+ seconds for 5K+ rows. Schedule this workflow for off-hours if your team accesses the sheet during business hours to avoid edit conflicts.

Ideas for what to build next

  • Add Deal Velocity TrackingCreate a second sheet tab that tracks how long opportunities spend in each stage by comparing today's export with previous days.
  • Set Up Slack NotificationsAdd a Slack node that posts a summary message with total pipeline value and deal count after each successful export.
  • Create Account-Level RollupsBuild a follow-up workflow that groups opportunities by account and calculates total pipeline value per customer in a separate summary sheet.

Related guides

Was this guide helpful?
Google Sheets + Salesforce overviewn8n profile →