Overview
The OneSignal + Google Sheets integration enables automatic syncing of custom events from your Google Sheets to OneSignal. This allows you to trigger automated Journeys and personalized messaging campaigns based on user behavioral data stored in your spreadsheets, perfect for teams that manage event data collaboratively.Requirements
- Access to Custom Events (currently in beta)
- Updated Account Plan (not available on free apps).
Google Sheets
- Google Account with access to the sheet containing event data
- Event spreadsheet with proper column structure for event data
- Sheet sharing permissions for OneSignal to access the data
- Consistent data format in your event tracking sheet
Setup
1
Prepare your event data sheet
Structure your Google Sheet with the required columns for event data:Required columns:
event_name
orevent_type
: The name of the event (String)user_id
oremail
: User identifier (String)timestamp
orcreated_at
: Event timestamp (Date/DateTime)properties
: Event properties as JSON or separate columns (Optional)
2
Configure sheet permissions
Share your Google Sheet with OneSignal’s service account:
- Open your Google Sheet
- Click Share button in the top right
- Add OneSignal’s service account email (provided during setup)
- Set permissions to Viewer (read-only access)
- Click Send to grant access
OneSignal will provide the specific service account email during the integration setup process.
3
Add integration in OneSignal
In OneSignal, go to Data > Integrations and click Add Integration.Select Google Sheets and provide:
- Sheet URL: The full URL of your Google Sheet
- Sheet Name: The specific tab/sheet name containing event data
- Header Row: Row number containing column headers (usually 1)
- Data Range: Cell range containing your event data (e.g.,
A2:F1000
)
4
Configure column mapping
Map your Google Sheets columns to OneSignal event fields:
- Event Name Column: Select the column containing event names
- User ID Column: Select the column with user identifiers
- Timestamp Column: Select the column with event timestamps
- Properties Columns: Select additional columns to include as event properties
You can map multiple columns as event properties. OneSignal will combine them into a single event payload.
5
Set sync schedule
Configure how often OneSignal should check for new event data:
- Sync Frequency: Choose from 15 minutes, hourly, or daily
- Incremental Sync: Enable to only sync new rows since last update
- Timestamp Filter: Only sync events within a specific time range
Google Sheets has API rate limits. More frequent syncing may be throttled for sheets with large datasets.
6
Test the connection
Click Test Connection to verify OneSignal can access your Google Sheet and read the event data correctly.
Event data mapping
Map your to OneSignal’s custom events format:OneSignal Field | Description | Required | |
---|---|---|---|
name | event_name | Event identifier | Yes |
external_id | user_id | User identifier | Yes |
timestamp | event_timestamp | When event occurred | No |
properties | event_data | No |
Advanced Configuration
Incremental Sync Setup
Configure incremental syncing to only process new events:- Timestamp Column: Ensure your sheet has a consistent timestamp column
- Sort Order: Keep events sorted by timestamp (newest last)
- Append-Only: Add new events to the bottom of your sheet
- Avoid Edits: Don’t modify historical event rows after they’re synced
Data Validation
Implement data validation in your Google Sheet:Collaborative Workflows
Best practices for team collaboration:- Named Ranges: Use named ranges for event data sections
- Protected Ranges: Protect header rows from accidental changes
- Comments: Add comments to explain event definitions
- Version History: Use Google Sheets’ version history for tracking changes
- Access Controls: Limit edit access to data entry team members
Performance Optimization
Optimize for large datasets:- Sheet Limits: Keep individual sheets under 10,000 rows for best performance
- Multiple Sheets: Use separate sheets for different event types
- Data Archival: Archive old data to separate sheets monthly
- Formulas: Minimize complex formulas in event data ranges
Google Sheets performs best with under 50,000 total cells. For high-volume event tracking, consider using a database source instead.