You can use Salesforce Data Loader to bulk delete old or unnecessary Salesforce Files.
For Salesforce Files, export the ContentDocument records (make sure you have the Query All Files permission), review/filter the CSV to keep only the files you want to remove, and then use Delete in Data Loader with the Id column.
Deleting a ContentDocument also deletes its related ContentVersion records, so make sure to take a backup and carefully verify the IDs before performing the deletion.
In short:
Data Loader → Export ContentDocument → Filter IDs → Delete using Data Loader
For production orgs, always take a backup and test with a small set first.
https://help.salesforce.com/s/articleView?id=000387186&type=1&utm
Hope This Helps!!
If you find this response helpful, please mark it as the Accepted Answer, as it may also help other Trailblazers.
1 answer