Workflows
Blocks
Integrations
Microsoft Excel 365

Microsoft Excel 365 Action Block

What it does: Read, write, and manage data in Microsoft Excel workbooks stored in OneDrive or SharePoint as part of your workflow automation.

📊

In simple terms: Automate spreadsheet operations -- read rows, append data, update cells, and manage worksheets and tables in Excel 365 workbooks.

When to Use This

Use the Excel 365 action when you need to:

  • ✅ Append new rows to a tracking spreadsheet automatically
  • ✅ Read data from Excel for use in workflow logic
  • ✅ Update specific rows based on matching criteria
  • ✅ Manage worksheets and tables programmatically
  • ✅ Use Excel as a lightweight database for workflow data

Example: When a new order is placed, append a row to the Orders spreadsheet with order details and update the inventory count in another worksheet.

Features

  • OAuth2 Authentication: Secure Microsoft identity platform connection
  • Row Operations: Read, append, update, and clear rows in worksheets
  • Worksheet Management: Get, add, and delete worksheets
  • Table Support: Work with structured Excel tables (read, append, lookup)
  • Workbook Discovery: List available workbooks in OneDrive
  • Variable Support: Use workflow variables for dynamic cell references and values

Setup

1. Connect Your Microsoft Account

  1. Click Connect Microsoft Account in the block settings
  2. Sign in with your Microsoft 365 account
  3. Grant the requested permissions (Files.ReadWrite.All)
  4. Your account will be linked securely via OAuth2

2. Configure Settings

  1. Select the desired Action from the dropdown
  2. Choose the Workbook from your OneDrive or enter its ID
  3. Select the Worksheet or Table to operate on
  4. Fill in action-specific fields (range, values, etc.)
⚠️

Excel workbooks must be stored in OneDrive or SharePoint to be accessible through this block. Local Excel files on your computer are not supported.

Supported Actions

Row Operations

ActionDescription
Read RowsRead data from a specified range or entire worksheet
Append RowsAdd new rows to the end of a worksheet or range
Update RowsModify existing rows based on range or criteria
Clear RowsClear content from a specified range

Worksheet Operations

ActionDescription
Get WorksheetsList all worksheets in a workbook
Add WorksheetCreate a new worksheet in the workbook
Delete WorksheetRemove a worksheet from the workbook

Table Operations

ActionDescription
Get Table RowsRead all rows from a named table
Get Table ColumnsRetrieve column definitions from a table
Append Table RowsAdd new rows to a named table
Lookup TableSearch for rows matching specific criteria

Workbook Operations

ActionDescription
Get WorkbooksList all Excel workbooks in your OneDrive

Using Variables

You can use workflow variables in any Excel field:

Cell Values for Append:

Column A: {{order.id}}
Column B: {{customer.name}}
Column C: {{order.total}}
Column D: {{date.now}}

Range Reference:

Sheet1!A1:D{{row.count}}

Lookup Value:

{{search.productSku}}

Response Mapping

Map results from Excel actions to workflow variables:

Available Values (Read Rows):

  • Rows: Array of row data with column values
  • Row Count: Number of rows returned
  • Range: The actual range that was read

Available Values (Append/Update):

  • Updated Range: The range that was modified
  • Rows Affected: Number of rows changed

Available Values (Lookup Table):

  • Matching Rows: Array of rows matching the criteria
  • Match Count: Number of matches found

Example Mapping:

Rows → {{excel.rows}}
Row Count → {{excel.rowCount}}
First Row Name → {{excel.rows[0].Name}}

Common Use Cases

1. Order Tracking Spreadsheet

Trigger: New order webhook Excel Action: Append Table Rows

Workbook: Sales Tracker.xlsx
Table: Orders
Order ID: {{order.id}}
Customer: {{order.customerName}}
Amount: {{order.total}}
Date: {{date.now}}
Status: New

2. Inventory Lookup

Trigger: Stock check request Excel Action: Lookup Table

Workbook: Inventory.xlsx
Table: Products
Lookup Column: SKU
Lookup Value: {{request.sku}}

Then use {{excel.matchingRows[0].Quantity}} in subsequent workflow steps.

3. Monthly Report Aggregation

Trigger: Schedule (1st of each month) Excel Action: Read Rows, then Add Worksheet

Read from: Sales Data!A1:F1000
New Worksheet Name: Summary {{date.previousMonth}}
Write aggregated totals to new worksheet

4. Employee Directory Update

Trigger: HR system webhook Excel Action: Lookup Table, then Update Rows

Lookup: Employee ID = {{employee.id}}
Update Fields:
  Department: {{employee.newDepartment}}
  Title: {{employee.newTitle}}
  Updated: {{date.now}}

Best Practices

Data Structure

  • ✅ Use Excel Tables (not raw ranges) for structured data -- they auto-expand and support named columns
  • ✅ Keep header rows consistent and descriptive
  • ✅ Use ISO date formats (YYYY-MM-DD) for date columns
  • ✅ Avoid merged cells in ranges that workflows interact with

Performance

  • ✅ Read only the range you need, not entire worksheets
  • ✅ Batch row appends when possible instead of one-at-a-time
  • ✅ Use Lookup Table instead of reading all rows and filtering in the workflow
  • ✅ Keep workbooks under 5 MB for optimal API performance

Data Integrity

  • ✅ Validate data types before writing to cells
  • ✅ Use the Lookup action to check for duplicates before appending
  • ✅ Clear ranges carefully -- this operation cannot be undone via the API
  • ✅ Consider using worksheet protection for critical data columns

Troubleshooting

Cannot Find Workbook

Check:

  • The workbook is stored in OneDrive or SharePoint (not locally)
  • Your Microsoft account has access to the file
  • Use Get Workbooks action to list all available workbooks

Append Rows Fails

Solutions:

  • Ensure the target worksheet or table exists
  • Verify that the number of values matches the number of columns
  • Check that data types match column formats (numbers, dates, text)

Read Returns Empty Data

Check:

  • The range reference is correct (e.g., Sheet1!A1:D100)
  • The worksheet name matches exactly (case-sensitive)
  • The workbook is not locked or checked out by another user

Table Lookup Returns No Matches

Check:

  • The lookup column name matches the table header exactly
  • The lookup value format matches the cell format (text vs. number)
  • Leading/trailing whitespace in cell values can cause mismatches

Limitations

  • Workbook Size: Large workbooks (>5 MB) may experience slower API responses
  • Row Limits: Excel 365 supports up to 1,048,576 rows per worksheet, but API operations on very large ranges may time out
  • Concurrent Access: Multiple workflows writing to the same workbook simultaneously may cause conflicts
  • Formulas: Appended data is written as values; cell formulas cannot be set through this block
  • API Rate Limits: Microsoft Graph API throttling applies
💡

Tip: For high-volume data operations, consider using a proper database instead of Excel. Excel works best as a lightweight data store for under 10,000 rows.

Related Blocks

  • OneDrive: Manage the workbook files themselves
  • SharePoint: Access Excel files in SharePoint document libraries
  • Google Sheets: Alternative spreadsheet integration
  • Condition: Add logic based on Excel data lookups
  • Loop: Iterate over rows returned from Excel
Indite Documentation v1.6.0
PrivacyTermsSupport