Help center

Google Sheets Integration

The Google Sheets integration automatically saves form submissions to your Google Spreadsheet, making it easy to analyze responses, share data with your team, and create visualizations.

Overview

When a form is submitted, Axiforms will:

  1. Connect to your Google account (OAuth)
  2. Map form fields to spreadsheet columns
  3. Append a new row with the submission data
  4. Support nested paths for organized data storage

Setting Up Google Sheets Integration

Step 1: Connect Your Google Account

  1. Navigate to your form's SettingsIntegrations
  2. Click on Google Sheets
  3. Click Connect Google Account
  4. You'll be redirected to Google to authorize Axiforms
  5. Grant permissions to access Google Sheets
  6. You'll be redirected back to Axiforms

Step 2: Select a Spreadsheet

After connecting, you'll see a dialog to select a spreadsheet:

  1. Choose from list: Select from your recent spreadsheets
  2. Enter ID manually: If you prefer, enter the spreadsheet ID from the URL

To find your Spreadsheet ID:

  • Open your Google Spreadsheet
  • Look at the URL: https://docs.google.com/spreadsheets/d/{SPREADSHEET_ID}/edit
  • Copy the {SPREADSHEET_ID} part

Step 3: Select a Sheet (Tab)

  1. After selecting a spreadsheet, choose which sheet (tab) to use
  2. The first sheet will be selected by default
  3. Data will be appended to this sheet

Step 4: Map Form Fields

  1. Click Add Field to start mapping
  2. For each form field:
    • Select the Form Field from the dropdown
    • Enter the Column Name in the spreadsheet
    • Field mappings are saved and reused for all submissions

Step 5: Enable and Save

  1. Enable the integration toggle
  2. Click Create Integration or Update Integration
  3. Test by submitting your form and checking the spreadsheet

Field Mapping

How Field Mapping Works

Field mappings define how form responses are saved to your spreadsheet:

  • Form Field: The field from your Axiforms form
  • Column Name: The column header in your Google Sheet

Example Mapping

Form FieldColumn NameResult
Email AddressEmailEmail addresses go to "Email" column
Full NameNameNames go to "Name" column
MessageCommentsMessages go to "Comments" column

Creating Column Headers

The first time data is added, Axiforms will create columns with the names you specify. If columns already exist, data will be appended to those columns.

Nested Paths

Google Sheets integration supports nested paths in your spreadsheet structure:

Example URL structure:

https://your-domain.com/f/survey/2024

This allows you to:

  • Organize forms by category (e.g., survey/2024, contact, feedback)
  • Use the same form mapping with different path configurations
  • Create a hierarchical structure in your spreadsheet

OAuth and Permissions

What Permissions Are Required?

Axiforms requests the following Google permissions:

  • View and manage Google Sheets: To read spreadsheet metadata and append rows
  • View Google Drive files (readonly): To list your spreadsheets for selection

Reconnecting Your Account

If you need to reconnect your Google account:

  1. Click Reconnect in the integration settings
  2. Re-authorize Axiforms
  3. Your existing mappings will be preserved

Security

  • OAuth tokens are stored securely in Axiforms's database
  • Tokens are automatically refreshed when they expire
  • You can revoke access at any time from Google Account Settings

Data Format

Spreadsheet Structure

When data is appended, it follows your field mappings:

TimestampEmailNameMessage
2024-01-15user@example.comJohn DoeHello...

Value Types

Axiforms automatically handles different value types:

  • Text: Saved as-is
  • Numbers: Saved as numbers
  • Dates: Saved in standard format
  • Multiple selections: Joined with commas
  • Objects/Arrays: Saved as JSON strings

Troubleshooting

"Failed to append row" error

Possible causes:

  • Spreadsheet is deleted or moved
  • You don't have edit permissions on the spreadsheet
  • Sheet name doesn't exist
  • Google account connection expired

Solutions:

  1. Verify the spreadsheet exists and you have access
  2. Check that the sheet name matches exactly (case-sensitive)
  3. Try reconnecting your Google account
  4. Verify column names match your field mappings

OAuth connection issues

If connection fails:

  • Ensure you have a Google account
  • Check that you granted all required permissions
  • Try disconnecting and reconnecting
  • Verify Axiforms is not blocked by your organization's security policies

Missing data in spreadsheet

  • Check that field mappings are correct
  • Verify the form fields match the mapped fields
  • Ensure the integration is enabled
  • Check Axiforms logs for error messages

Token expiration

OAuth tokens are automatically refreshed, but if refresh fails:

  • Reconnect your Google account
  • Ensure you granted offline access permissions
  • Check that your Google account is active

Best Practices

  1. Pre-create columns: While Axiforms creates columns automatically, pre-creating them gives you better control over formatting and formulas
  2. Use consistent column names: Keep column names consistent across multiple forms for easier data consolidation
  3. Format your spreadsheet: Set up number formats, dates, and validation rules before data starts flowing
  4. Protect headers: Lock the header row in Google Sheets to prevent accidental changes
  5. Set up filters: Add filter views for easy data analysis

Advanced Usage

Multiple Forms, One Spreadsheet

You can use the same spreadsheet for multiple forms:

  1. Create separate sheets (tabs) for each form
  2. Configure each form's integration to use the appropriate sheet
  3. Or use a single sheet with a "Form Name" column to distinguish submissions

Data Validation

Set up Google Sheets data validation to ensure data quality:

  • Email validation: Ensure email columns contain valid emails
  • Number ranges: Validate numeric fields
  • Dropdown lists: Restrict values to specific options

Formulas and Automation

Use Google Sheets formulas with your form data:

  • COUNTIF: Count submissions matching criteria
  • SUM: Aggregate numeric responses
  • AVERAGE: Calculate averages
  • Google Apps Script: Create custom automation

API Reference

Axiforms uses the Google Sheets API v4 to append data:

POST https://sheets.googleapis.com/v4/spreadsheets/{spreadsheetId}/values/{range}:append

For more information, see the Google Sheets API documentation.