Remove Header Footer from Excel in Power Automate
PDF4me Remove Header Footer from Excel is a Power Automate action that strips selected header and footer sections from a workbook before re-branding or archiving it. Use it to clear old logos, quarter labels, or confidential markings from Left, Center, or Right zones on specific sheets or the whole file.
What this action does
PDF4me Remove Header Footer from Excel clears any of six independent zones, Header Left, Header Center, Header Right, Footer Left, Footer Center, and Footer Right, on an existing workbook. Target specific worksheets by name or index, or leave both empty to clean every sheet in one pass.
How Do I Authenticate My Power Automate Flow?
Every PDF4me action in Power Automate requires a valid connection. Create or select one that holds your PDF4me API key so the flow can authenticate Excel header/footer requests securely.
Important Facts You Should Not Miss

Map File Content, set File Name, then flip only the header/footer zones you want removed to Yes.
Parameters
Required: only File Content must be provided. File Name and all six removal flags are optional. Worksheet Names, Worksheet Indexes, and Culture Name are conditional advanced parameters that only matter if you need targeting or localization beyond the defaults.
| Parameter | Required | What it does | Example |
|---|---|---|---|
| File Content | Required | Base64 content of the source Excel workbook, mapped from SharePoint, OneDrive, or another prior action. | [File Content from Get file content] |
| File Name | Optional | Excel filename including extension (.xlsx or .xls), used for processing and output identification. | add_header_sample_file.xlsx |
| Remove Header Left | Optional | Yes clears the left section of the header, No preserves it. Defaults to No. | Yes |
| Remove Header Center | Optional | Yes clears the center section of the header, No preserves it. Defaults to No. | No |
| Remove Header Right | Optional | Yes clears the right section of the header, No preserves it. Defaults to No. | No |
| Remove Footer Left | Optional | Yes clears the left section of the footer, No preserves it. Defaults to No. | No |
| Remove Footer Center | Optional | Yes clears the center section of the footer, No preserves it. Defaults to No. | No |
| Remove Footer Right | Optional | Yes clears the right section of the footer, No preserves it. Defaults to No. | No |
| Worksheet Names | Conditional | Advanced parameter. List of worksheet names to target, for example Sheet1 or Report. Leave empty along with Worksheet Indexes to process every sheet. | ["Sheet1", "Report"] |
| Worksheet Indexes | Conditional | Advanced parameter. List of 0-based worksheet indexes to target. Combines with Worksheet Names if both are set. | [0, 2] |
| Culture Name | Conditional | Advanced parameter. Culture/locale code for processing, for example en-US or de-DE. Blank uses the invariant culture. | en-US |
Output Fields
| Field | Type | What it contains |
|---|---|---|
document | Base64 | The Excel workbook with the selected header/footer sections removed. |
Success | Boolean | true if the action completed, false if it failed. |
ErrorMessage | String | Error description, null when Success is true. |
Errors | Array | Detailed error objects, empty when Success is true. |
What Do the Common Error Messages Mean?
| Error Message | Cause | Solution |
|---|---|---|
| Request is empty | The request object is null. | Provide a valid request object. |
| Document is empty | File Content is null or empty. | Provide a valid Excel document in File Content. |
| Invalid worksheet selection | Worksheet names don't exist or indexes are out of range. | Use existing worksheet names or valid 0-based indexes. |
| Available worksheets in workbook (X total) | Informational message shown when worksheet selection fails. | Review worksheet names/indexes and use a valid value from the X available worksheets. |
How Do I Set Up Remove Header Footer in Power Automate?
- Add PDF4me → Excel - Remove Header Footer to your Power Automate flow.
- Map File Content from a previous action (SharePoint, OneDrive, or Get file content) and set File Name.
- Set Remove Header Left, Remove Header Center, or Remove Header Right to Yes for each header zone you want cleared.
- Set Remove Footer Left, Remove Footer Center, or Remove Footer Right to Yes for each footer zone you want cleared.
- Expand Advanced parameters to target specific Worksheet Names or Worksheet Indexes, or leave both empty to process every sheet. Run the flow, the cleaned workbook returns as document.
Typical Setups
Workflow ExamplesCommon Power Automate flow patterns using Remove Header Footer.
- A rebranding initiative flow triggers on a SharePoint template library.
- Get file content retrieves each Excel template.
- Remove Header Footer sets all six removal flags to Yes, with Worksheet Names and Worksheet Indexes left empty to clear every sheet.
- Add Text Header Footer then stamps the new branding onto the cleaned workbook.
- A scheduled flow runs at the start of each quarter.
- Get file content retrieves the quarterly report template.
- Remove Header Footer sets Remove Header Center and Remove Footer Left to Yes, keeping Remove Header Right at No to preserve page numbers, targeting Worksheet Names ["Summary", "Financial Data"].
- A follow-up action inserts the new quarter label into the cleared header.
- A flow triggers when an internal report is marked for client delivery.
- Get file content retrieves the internal Excel report.
- Remove Header Footer sets all footer flags and Remove Header Left, Remove Header Center to Yes, keeping Remove Header Right at No to preserve pagination, using Worksheet Indexes [0, 1, 2] for the main sections.
- The sanitized workbook is emailed to the client stakeholder.
Practical Tips
Cheat Sheet
| Field | Value |
|---|---|
| Action | Excel - Remove Header Footer |
| Required fields | File Content |
| Header removal flags | Remove Header Left, Center, Right (each Yes/No, default No) |
| Footer removal flags | Remove Footer Left, Center, Right (each Yes/No, default No) |
| Advanced parameters | 3 total: Worksheet Names, Worksheet Indexes, Culture Name |
| Output | document (Base64 workbook) + Success + ErrorMessage + Errors |
Common Questions
Industry Use Cases & Applications
- Corporate Rebranding
- Finance & Accounting
- Human Resources
- Sales & Marketing
- Legal & Compliance
- Operations & Manufacturing
- Company Rebranding: Remove old company logos and names from all Excel templates
- Merger Integration: Clean headers/footers before applying merged entity branding
- Division Restructure: Remove old division headers from departmental templates
- Product Line Changes: Clean product branding from sales and marketing templates
- Quarter-End Cleanup: Remove previous quarter information from financial templates
- Year-End Standardization: Clean year-specific headers before new fiscal year
- Audit Preparation: Remove internal review comments from audit deliverables
- Client Reports: Sanitize internal headers/footers from client-facing financial reports
- Template Updates: Remove outdated HR policy headers from employee templates
- Benefits Enrollment: Clean previous year enrollment headers from new templates
- Performance Reviews: Remove old review period headers from evaluation templates
- Onboarding Cleanup: Standardize new hire templates by removing old headers
- Campaign Cleanup: Remove old campaign headers from reusable sales templates
- Pricing Updates: Clean outdated pricing period headers from rate sheets
- Client Proposals: Remove internal review headers from client deliverables
- Territory Changes: Update sales territory headers by removing old assignments
- Contract Templates: Remove old version headers from legal templates
- Policy Updates: Clean outdated policy dates from compliance documents
- Regulatory Changes: Update regulatory reference headers by removing old citations
- Audit Cleanup: Remove internal audit notes from final compliance reports
- SOP Updates: Remove old revision headers from standard operating procedures
- Quality Standards: Clean outdated ISO version headers from quality templates
- Safety Updates: Remove old safety regulation headers from training materials
- Vendor Changes: Clean old vendor logos from procurement templates