Comments, notes, and Track Changes revision history are among the most commonly overlooked sources of sensitive data in Excel files. They accumulate during the normal editing process and can reveal internal discussions, author identities, negotiation strategies, and the full history of every edit made to a document. Before sharing any spreadsheet externally, you need to systematically find and remove all of these elements.
Comments and Track Changes are collaboration tools designed for internal use. They let team members annotate cells with context, flag questions, and maintain a detailed audit trail of every insertion, deletion, and format change. The problem arises when these internal artifacts travel with the file to an external recipient who was never meant to see them.
Unlike visible cell data, comments and revision history sit in background layers of the spreadsheet. Users often forget they exist because they are not part of the primary grid view. A file that looks perfectly clean on screen may contain dozens of comments with candid internal assessments and a complete revision log showing every value that was changed, who changed it, and when.
Each of these scenarios could have been avoided by removing comments and Track Changes before the file left the organization. The following sections cover every type of annotation and revision data in Excel and how to eliminate them.
Excel has evolved its annotation features over time, and the terminology can be confusing. Modern versions of Excel (Microsoft 365) distinguish between three types of cell-level annotations:
The original annotation feature, now called “Notes” in Microsoft 365. These are simple text boxes attached to a cell, indicated by a small red triangle in the upper-right corner. Each note records the author name of the person who created it. Notes are stored in the xl/comments*.xml files inside the XLSX package.
Introduced for collaborative editing, threaded comments support replies and @mentions. They appear in a sidebar panel and are indicated by a purple indicator on the cell. Threaded comments are stored in xl/threadedComments/ within the XLSX package and include author names, timestamps, and the full reply chain.
Handwritten annotations created with a stylus or touch input. These are stored as drawing objects in xl/drawings/ and can be easily overlooked because they may not be visible on all devices or zoom levels.
All three types embed the author’s identity, and all three travel with the file when shared. Even if you have stripped the document properties (Title, Author, Company), the author attribution within individual comments and notes remains intact. This means a file you thought was anonymized may still reveal exactly who wrote each annotation.
Track Changes is Excel’s built-in feature for recording every edit made to a workbook. When enabled, it logs the cell address, old value, new value, author, timestamp, and type of change (insertion, deletion, or modification) for every edit. This revision log is stored inside the file and persists until explicitly removed.
In older Excel formats (.xls), Track Changes data was stored in a hidden “revision log” stream within the binary file. In modern .xlsx files, revision data is stored in the xl/revisions/ folder inside the ZIP package. Shared workbooks (the legacy co-authoring model) maintain a particularly detailed revision history that can span thousands of changes.
Every original value before it was changed is recorded. If you updated a price from $50,000 to $75,000, the original amount is preserved in the revision history. This is often the most damaging disclosure — it shows what numbers you started with.
Each change records who made it and exactly when. This creates a detailed timeline of who worked on the file, when they contributed, and what they changed.
Rows, columns, and cells that were deleted are preserved in the revision log with their original content. Data you thought was gone may still be fully recoverable from the Track Changes history.
Sheet insertions, deletions, renames, and moves are all logged. This can reveal the existence of worksheets that were created and then removed before sharing.
Windows offers several approaches to removing comments and notes, ranging from manual methods for individual files to the Document Inspector for comprehensive cleanup.
Go to Review > Show All Comments (or Show Notes in Microsoft 365) to make every annotation visible across all sheets. Use Next Comment and Previous Comment to cycle through them.
Right-click any cell with a red triangle indicator and select Delete Comment (or Delete Note). For threaded comments, click the three-dot menu on the comment and select Delete Thread.
Select all cells with Ctrl+A, then go to Home > Clear > Clear Comments and Notes. This removes all notes from the active sheet. Repeat for every sheet in the workbook.
Go to File > Info > Check for Issues > Inspect Document. Save the file when prompted.
Ensure Comments and Annotations is checked. You can also check other categories like Document Properties and Personal Information for a more thorough cleanup.
The Inspector scans all sheets and reports what it finds. If comments are detected, click Remove All next to the Comments and Annotations category.
Run the Inspector again to confirm all comments have been removed. Threaded comments in Microsoft 365 may require a second pass in some versions.
The Document Inspector is the recommended approach because it scans the entire workbook at once, including all sheets, and can remove multiple types of hidden data in a single operation. Manual deletion is error-prone because it requires you to remember to check every sheet individually.
Excel for Mac has the same core functionality but with slightly different menu paths and some limitations in older versions.
Select all cells (Cmd+A), then go to Edit > Clear > Clear Comments. In Microsoft 365 for Mac, you can also use Home > Clear > Clear Comments and Notes. Repeat for each worksheet.
In Microsoft 365 for Mac, the Document Inspector is available under Tools > Protect Document > Remove Personal Information, or through File > Check for Issues depending on your version. Note that older versions of Excel for Mac (2016 and earlier) did not include the Document Inspector — for those versions, manual removal or a VBA script is your only option.
Some versions of Excel for Mac do not fully remove threaded comments through the Document Inspector. If your file was created or edited in Microsoft 365 with threaded comments, verify removal by opening the cleaned file on Windows or by inspecting the XML directly.
Removing Track Changes requires a different approach than removing comments. Simply turning off Track Changes does not delete the existing revision history — you must explicitly accept or reject all changes, and in some cases take additional steps to purge the revision log.
Go to Review > Accept/Reject Changes (or Review > Changes > Accept All Changes in newer versions). Select Not yet reviewed for the “When” filter and leave “Who” and “Where” set to “Everyone” and “All.” Click Accept All to finalize every pending change.
Go to Review > Track Changes > Highlight Changes and uncheck Track changes while editing. This disables the feature and, for non-shared workbooks, deletes the revision history. You will be prompted to confirm.
If the workbook is shared (legacy sharing model), go to Review > Share Workbook and uncheck Allow changes by more than one user. This removes the shared workbook revision log, which can contain an extensive history of changes by all users.
Use File > Save As to save a fresh copy as .xlsx. This creates a clean file without residual revision data. The original file retains its history as a backup.
Microsoft 365’s modern co-authoring (AutoSave with OneDrive/SharePoint) uses a different mechanism than legacy Track Changes. Version history is stored by the cloud service, not in the file itself. However, when you download the file or save it locally, some revision metadata may be embedded. The safest approach is to download the file, open it in desktop Excel with AutoSave off, run the Document Inspector, and then Save As a new .xlsx file.
For workbooks with many sheets or when you need to process multiple files, VBA macros provide a reliable way to remove all comments and notes programmatically. This eliminates the risk of missing a sheet during manual cleanup.
Sub RemoveAllCommentsAndNotes()
Dim ws As Worksheet
Dim commentCount As Long
commentCount = 0
For Each ws In ThisWorkbook.Worksheets
' Remove legacy comments/notes
Dim c As Comment
For Each c In ws.Comments
commentCount = commentCount + 1
c.Delete
Next c
Next ws
MsgBox "Removed " & commentCount & " comments/notes " & _
"from all sheets.", vbInformation
End SubOpen the VBA Editor with Alt+F11, insert a new module, paste the code, and run it. This macro iterates through every worksheet and deletes all legacy comments and notes.
Sub RemoveTrackChanges()
On Error Resume Next
' Accept all tracked changes
ThisWorkbook.AcceptAllChanges
' Turn off change tracking
If ThisWorkbook.KeepChangeHistory Then
ThisWorkbook.KeepChangeHistory = False
End If
' Unshare if shared
If ThisWorkbook.MultiUserEditing Then
ThisWorkbook.ExclusiveAccess
End If
On Error GoTo 0
MsgBox "Track Changes removed and change " & _
"tracking disabled.", vbInformation
End SubThis macro accepts all pending changes, disables the change history log, and removes shared workbook status if applicable. After running it, save the file as .xlsx to ensure a clean output.
When you need to clean comments from many files at once — such as before a bulk file transfer or as part of a data release pipeline — Python with the openpyxl library provides a scriptable solution.
import openpyxl
from pathlib import Path
def remove_comments(file_path: str, output_path: str) -> dict:
"""Remove all comments from an Excel file."""
wb = openpyxl.load_workbook(file_path)
stats = {"sheets": 0, "comments_removed": 0}
for ws in wb.worksheets:
stats["sheets"] += 1
for row in ws.iter_rows():
for cell in row:
if cell.comment:
stats["comments_removed"] += 1
cell.comment = None
wb.save(output_path)
wb.close()
return stats
# Process all .xlsx files in a directory
input_dir = Path("./input")
output_dir = Path("./output")
output_dir.mkdir(exist_ok=True)
for xlsx_file in input_dir.glob("*.xlsx"):
out_path = output_dir / xlsx_file.name
result = remove_comments(str(xlsx_file), str(out_path))
print(f"{xlsx_file.name}: removed "
f"{result['comments_removed']} comments "
f"from {result['sheets']} sheets")Install openpyxl with pip install openpyxl. This script processes every .xlsx file in the input directory, removes all cell comments, and saves clean copies to the output directory. Note that openpyxl handles legacy comments but may not fully process threaded comments from Microsoft 365 — for those, the XML-level approach below is more reliable.
The most thorough way to verify that all comments and Track Changes have been removed is to inspect the raw XML inside the XLSX file. This catches anything that the GUI tools or libraries might miss, including threaded comments and orphaned revision logs.
Make a copy of the file, change the extension from .xlsx to .zip, and extract the contents to a folder. You will see the internal directory structure of the Office Open XML package.
Look for files named xl/comments1.xml, xl/comments2.xml, etc. Each one corresponds to a worksheet. If these files exist and contain <comment> elements, comments are still present.
Look for the xl/threadedComments/ directory. If it exists and contains XML files, threaded comments are still embedded in the file.
Look for the xl/revisions/ directory or any files named revisionHeaders.xml or revisionLog*.xml. These contain the Track Changes history.
Look for xl/persons/person.xml. This file contains the identity information (names, user IDs, provider data) for everyone who authored comments or threaded discussions. Even if comments are deleted, this file may persist.
If any of these files remain after your cleanup, you can delete them from the ZIP archive and re-save as .xlsx. However, you must also update the relationship files ([Content_Types].xml and the relevant .rels files) to remove references to the deleted files, or Excel may report the file as corrupt when opening it.
Our free online tool provides instant visibility into the comments, notes, and revision metadata embedded in your Excel files. Upload your file and the analyzer will report all detected annotations, including the author name associated with each comment, threaded discussion threads, and any Track Changes revision data.
This gives you a clear picture of what needs to be removed before sharing, without manually inspecting each sheet or digging through XML. Use it as a final verification step after running the Document Inspector or your cleanup script to confirm that nothing was missed.
Use this checklist every time you prepare an Excel file for external sharing. Work through each item systematically to ensure no comments, notes, or revision data travel with the file.
Rather than cleaning up comments and Track Changes every time you share a file, consider establishing workflows that minimize their accumulation in the first place.
Maintain a “working copy” for internal collaboration (with comments and Track Changes enabled) and create a clean “distribution copy” for external sharing. Never send the working copy directly.
Use your organization’s collaboration tools (Teams, Slack, email) for discussions instead of cell comments. This keeps the conversation accessible to your team while keeping the file clean.
Only enable Track Changes when you have a genuine need for an audit trail. For routine files, the revision history adds risk without benefit.
Incorporate a Document Inspector step into your standard process for sending files externally. Some organizations add this to their email gateway or file-sharing approval workflow.
Ensure everyone who works with shared spreadsheets understands that comments and Track Changes travel with the file. A brief awareness session can prevent costly leaks.
Comments, notes, and Track Changes are essential collaboration features, but they become liabilities the moment a file leaves your organization. They expose author identities, internal discussions, negotiation strategies, and the complete history of every edit — information that recipients can access with no specialized tools.
The key takeaway is that turning off Track Changes or closing the comments pane does not remove the data. You must actively delete comments, accept all tracked changes, disable change tracking, and ideally Save As a new file to ensure a clean slate. The Document Inspector, VBA macros, Python scripts, and XML-level inspection each provide different levels of thoroughness depending on your needs.
Make comment and Track Changes removal a standard step in your file-sharing workflow. Use our MetaData Analyzer as a final verification to confirm your files are truly clean before they reach anyone outside your organization.