How to Delete All Comments from PDF Files in Adobe Acrobat
Question details
The user needs a method to remove every comment or annotation from a PDF and automate this deletion process across many files using Adobe Acrobat Pro.

- Product
- Adobe Acrobat Pro
- Device & OS
- not provided
- Scenario
- Preparing or cleaning up multiple PDF documents for final distribution by automatically wiping all markups and review notes.
- Observed behavior
- The PDF files currently contain multiple annotations, requiring a batch processing script or tool to destroy the comments automatically rather than deleting them manually one by one.
Before running any batch deletion scripts, copy your original PDF files to a separate folder so you do not accidentally overwrite files you might need to reference later.
Use JavaScript in Acrobat Pro Action Wizard
Create a custom Action in Acrobat Pro using JavaScript to automatically delete all annotations across multiple files.
Adobe Acrobat Pro allows you to automate repetitive tasks using the Action Wizard combined with custom JavaScript. By writing a simple script to destroy all annotations, you can process an entire folder of PDFs at once.
Launch Adobe Acrobat Pro, click on the 'Tools' tab, and select 'Action Wizard' from the list of available tools.
Click 'New Action' in the toolbar. In the left panel under 'Choose tools to add', expand 'More Tools' and click 'Execute JavaScript'. Click the '+' icon to add it to your Action steps on the right.
Click 'Specify Settings' under the Execute JavaScript step you just added. Paste this exact code into the window: this.syncAnnotScan(); var annots = this.getAnnots(); if (annots) { for (var i = annots.length - 1; i >= 0; i--) annots[i].destroy(); } then click OK.
Under 'Files to be Processed', you can select 'Add Folder' to target a directory of PDFs. Uncheck 'Prompt user' so the script runs automatically. Click 'Save', name your Action, and run it whenever you need to strip comments from files.

Use a Third-Party Batch Processing Tool
If you do not have a license for Adobe Acrobat Pro, you can use specialized batch cleaning utilities.
Manage and Delete PDF Comments with WPS Office
WPS Office provides an intuitive, user-friendly interface for managing, viewing, and deleting comments from your PDF documents. It serves as an excellent all-in-one editor for handling document reviews and cleanups.
- 1. Open Your PDF in WPS Office: Launch WPS Office and open the PDF file that contains the comments you want to remove.
- 2. Access the Comment Panel: Navigate to the 'Comment' tab on the top ribbon, and click the 'Comment List' icon on the left pane to display all document annotations.
- 3. Delete Unwanted Comments: Select the comments from the list, right-click, and choose 'Delete'. To remove multiple comments at once, hold the Shift or Ctrl key while selecting them in the list, then press the Delete key.

Frequently Asked Questions
Will deleting annotations via JavaScript also remove stamps and sticky notes?
Yes. In Adobe Acrobat's JavaScript API, elements like stamps, sticky notes, highlights, text boxes, and drawing markups are all classified as annotations and will be successfully destroyed by the script.
Can I recover comments deleted by an Action script?
No. Once the Action wizard processes the files and saves them, the comments are permanently removed. This is why it is critical to always run batch scripts on a copy of your files.
Why isn't the Acrobat JavaScript removing comments from my file?
The PDF might be protected by security settings that restrict commenting or document assembly. You will need to remove the security password and enable editing permissions before the JavaScript can modify the file.
Do I need programming skills to automate this in Acrobat Pro?
No programming skills are required. You only need to copy and paste the provided JavaScript code into the Action Wizard once, and Acrobat will handle the automation going forward.




