n8n

How to Sync Shopify Customers for Email Marketing?

Keep your Shopify customer list fresh in Google Sheets and create a ready to import CSV for Squarespace contacts. Great for marketing teams that need clean email lists for campaigns without manual exports.

Runs on a schedule or on demand, calls the Shopify Customers API, and follows next page links to capture every record. A code step reads the Link header to find the page cursor, loops until no more pages, and merges all results. Each customer is then split into single items, written to a chosen Google Sheet with append or update, and also formatted into a headerless CSV file that matches Squarespace contact import. This means complete coverage, fewer duplicates, and a file that is ready to upload.

Setup needs a Shopify access token with read customers and a Google Sheets connection. Replace your store domain in the request URL and pick the target spreadsheet and sheet. Expect a sharp cut in list prep time and fewer data errors. Use it for email campaign imports, list cleanup, and contact enrichment across your store.

What are the key features?

  • Runs by schedule or manual test for flexible control
  • Fetches Shopify customers with id, email, first name, and last name
  • Parses the Link header to read the next page cursor and loops until complete
  • Merges all pages into one list to avoid missing records
  • Splits customers into single items for clean processing
  • Writes to Google Sheets using append or update with mapped columns
  • Builds a headerless CSV file that matches Squarespace contacts import
  • Provides a binary file output you can download from the execution

What are the benefits?

  • Reduce manual exports from 60 minutes to 5 minutes per campaign
  • Automate 100 percent of customer list updates
  • Improve data accuracy by 90 percent by avoiding copy and paste
  • Handle large lists with cursor paging across many thousands of customers
  • Connect Shopify and Google Sheets in one flow
  • Create an import ready CSV for Squarespace with no extra edits

How do you set it up?

  1. Import the template into n8n: Create a new workflow in n8n > Click the three dots menu > Select 'Import from File' > Choose the downloaded JSON file.
  2. You'll need accounts with Shopify and Google Sheets. See the Tools Required section above for links to create accounts with these services.
  3. In the n8n credentials manager, create a Shopify Access Token credential. In your Shopify admin, go to Apps and sales channels > Develop apps, create an app, grant read customers scope, install the app, and copy the Admin API access token. Enter your shop domain and token in n8n and save.
  4. Connect Google Sheets in n8n by creating a Google Sheets OAuth credential. Sign in with the correct Google account and allow the requested permissions.
  5. Open the Get Customers node and replace the store part of the URL with your domain in the format https://your-store.myshopify.com. Keep the API version and query parameters as provided.
  6. Ensure the Get Customers node returns Full Response so headers are available for paging. Leave limit 250 and the listed fields to pull a stable set of data.
  7. Check the Customers Spreadsheet node and select your target spreadsheet and sheet. Map Email address, First name, Last name, and Shopify Customer ID to the matching columns. Use append or update to reduce duplicates.
  8. If you do not have a sheet yet, create one with the four columns in the same order and share it with the Google account you used for the credential.
  9. Set the Schedule Trigger to the interval you want, such as daily or hourly, and activate the workflow.
  10. Run a manual test. Confirm that rows appear in the Google Sheet and that a binary file is produced by the Convert to Squarespace contacts csv node. Download the file and spot check a few rows.
  11. If you see 401 or 403 errors from Shopify, review the access token, store domain, and make sure read customers is granted. If the sheet does not update, confirm sharing and that the sheet name and tab are correct.
  12. If paging stops early, verify that the Extract page_info and Assign page_info parameter nodes remain connected and that the Get Customers node is set to Full Response.

Tools Required

$24 / mo or $20 / mo billed annually to use n8n in the cloud. However, the local or self-hosted n8n Community Edition is free.

Google Sheets

Sign up

Free: $0 (Google Sheets API usage has no additional cost; quota limits apply)

Shopify

Sign up

Starter plan: $5 / mo

Similar Templates

Join Futurise to access 1,200+ automation templates

Get instant access to ready-made automation workflows for n8n, Make.com, AI agents, and more. Download, customise, and deploy in minutes.