What still uses the field I am deleting?
Salesforce will not delete a custom field while another component still points at it. The message prints that sentence once for every blocker, followed by the type and Id of the blocker.
The most common type is Flow Version, and that surprises people. A flow you retired two years ago, or a draft you never activated, still holds a reference to the field. Gearset's help center says the same: the deletion is blocked by references in any flow in the target, even deactivated older versions (Gearset Help Center, 09-12-2025).
Why do old flow versions block a delete?
- Flow versions. Each saved version keeps its own references, active or not.
- Apex classes and triggers that read or write the field.
- Validation rules, formula fields, workflow field updates and roll-up summaries that use it in a formula.
- Reports, email templates, Visualforce pages and Lightning components.
Page layouts did not block the delete in this test, even though several layouts use the field.
What does the delete error look like?
A destructive change for Account.Active__c in a developer org, sent as a check-only deploy with an empty package.xml:
Account.Active__c (CustomField)
This custom field is referenced elsewhere in salesforce.com. : Flow Version - 301Ka000000ZuZc.
This custom field is referenced elsewhere in salesforce.com. : Flow Version - 301Ka000000ZwK7.
This custom field is referenced elsewhere in salesforce.com. : Flow Version - 301Ka000000ZwNp.
...
The list ran to eight flow versions. One of them was a draft that had never been activated. The Id starts with 301, which is the prefix for a flow version.
How do I fix it in Setup?
- Copy each Id from the message. Open Setup > Flows, find the flow that owns that version (Setup > Process Automation > Flows, then the flow, then View Details and Versions).
- Open the active version, remove the field from it, save and activate a new version.
- Delete the old versions that still hold the field. Setup > Flows > open the flow > Versions > Delete on each inactive version. Drafts count, so delete them as well.
- Search Apex and formulas for the field name: Setup > Where is this used? on the field page lists most dependents.
- Fix the other blockers, then run the destructive change again.
How do I fix it with the CLI?
To find the flow version behind a 301 Id, query it:
sf data query --use-tooling-api -o <target-alias> -q "SELECT Id, VersionNumber, Status, Definition.DeveloperName FROM Flow WHERE Id IN ('301Ka000000ZuZc')"
To check before you delete for real:
sf project deploy start --dry-run --manifest package.xml --post-destructive-changes destructiveChanges.xml -o <target-alias>
destructiveChanges.xml does not support wildcards, so list the field by full name (Metadata API Developer Guide).
How do I clean up before I delete a field?
Clean up old flow versions on a schedule. A flow with fifty versions makes every field change harder. Before any delete, check Where is this used? and run the destructive change as a check-only deploy against the target first.
Deleted fields lose their data. Export the data you want to keep before the real delete.
Clientell AI takes a snapshot before every deploy, so a field delete you regret can be rolled back. See AI Salesforce deployments. The flow glossary entry covers versions and the validation rule glossary entry covers formulas.
The other delete error: deleting a class that is still used.
Questions about deleting a referenced custom field
Why does an inactive flow block the delete?
Because the version still contains the field reference. Salesforce checks all stored versions, not only the active one. Delete the old versions or edit them.
Can I delete a flow version that is a draft?
Yes. Open the flow in Setup > Flows, go to Versions and delete the draft. An active version has to be deactivated first.
Does a check-only destructive deploy remove anything?
No. It validates and returns the same messages as a real run, then discards the result.
Will a change set let me delete the field?
No. Change sets cannot delete components, as the change set errors guide explains. Use a destructive change through the Metadata API, or delete the field in the org itself once the references are gone.