What breaks if I delete this field?

A deleted field sits in the Recycle Bin for a short while, but everything that depends on it breaks straight away, and those dependents are spread across flows, formulas, code and permissions. Ask before you click Delete, and get the full list with each item named.

For admins, developers and release managers

Short answer

Ask your AI assistant “can I delete this field?”. sf-intelligence checks your org’s metadata and answers yes or no, names every component that depends on the field, and lists the kinds of metadata it couldn’t check. On the demo org, Invoice Amount has 3 blockers. It never deletes anything itself.

A real answer from the demo org

Two questions asked of Verdant, the demo org: the field on its own, then the same delete as part of a deployment.

Question

“Can I delete the Amount field on Invoice?”

No 3 things depend on it.

Next: Change those three first, then delete the field.

Blocking
  • Apex classPaymentServiceApexClass:PaymentService

    Reads the field. Salesforce will refuse the delete while this code references it.

  • Formula fieldInvoice BalanceCustomField:Invoice__c.Balance__c

    Uses the field in its formula.

  • Roll-up summaryProject › Total InvoicedCustomField:Project__c.Total_Invoiced__c

    Sums the field across a project’s invoices.

What it checked
  • Found Apex, Formulas, Roll-ups
  • Nothing in Flows, Workflow rules, Validation rules
  • Not checked Reports, dashboards and list views, Lightning pages and components, Visualforce, Quick actions and buttons, Assignment, auto-response and escalation rules, Restriction and scoping rules, OmniStudio cards, Email templates, DLRS roll-up definitions, Plain-text mentions of the field name in code

“Not checked” means those kinds of metadata were not in the snapshot, so the answer says so instead of claiming nothing is there.

It also flags Amount as financial data (a pattern match, not a certainty), so a delete may need a data-retention sign-off.

For developers: the tool call

Your assistant made this call to the sf-intelligence MCP server:

{
  "name": "sfi.safe_to_delete_field",
  "arguments": {
    "fieldId": "CustomField:Invoice__c.Amount__c"
  }
}
Question

“Is this deployment risky? It deletes Invoice Amount and changes the Project On Approve flow.”

No-go 1 blocking change, 1 to review.

Next: Move PaymentService, the Balance formula and the roll-up off Amount, then run the review again.

Blocking
  • Field · deletedInvoice › AmountCustomField:Invoice__c.Amount__c

    Deleting it breaks what depends on it.

    • Apex classPaymentServiceApexClass:PaymentService
    • Formula fieldInvoice BalanceCustomField:Invoice__c.Balance__c
    • Roll-up summaryProject › Total InvoicedCustomField:Project__c.Total_Invoiced__c
Review first
  • Flow · changedProject On ApproveFlow:Project_On_Approve

    No dependents found, but Lightning pages, Lightning components and quick actions were not in the snapshot, so it can’t call this safe.

A change it cannot fully check is marked “review”, never “safe”.

No overlapping field writes or save loops on Invoice or Project involve these changes.

You can hand it a package.xml, a destructiveChanges.xml or the file list from a git diff instead of naming components.

For developers: the tool call

Your assistant made this call to the sf-intelligence MCP server. sfi.review_change isn’t in the short default tool list, so it runs through sfi.run_analysis:

{
  "name": "sfi.run_analysis",
  "arguments": {
    "name": "sfi.review_change",
    "args": {
      "components": [
        {
          "componentId": "CustomField:Invoice__c.Amount__c",
          "changeKind": "deleted"
        },
        {
          "componentId": "Flow:Project_On_Approve",
          "changeKind": "modified"
        }
      ]
    }
  }
}

Recorded with sf-intelligence 0.8.0 on the built-in demo org. The wording is ours; the facts are the tool’s. More real answers.

Why a plain AI assistant gets this wrong

Ask a general chatbot whether you can delete a field and it lists the places fields are usually used: page layouts, reports, validation rules. It can’t know which of those exist in your org, so it either guesses or tells you to check everything yourself. sf-intelligence answers from your org’s actual metadata, so the list is your list, with each item named.

How to read the answer

The answer comes in three parts. Blocking items are things Salesforce will refuse the delete over, or that will break straight after it. What it checked shows where it looked and found something, where it looked and found nothing, and what it couldn’t look at. A short next step tells you what to change first.

A clean answer means no dependents were found in the kinds of metadata that were checked. That is a narrower claim than “unused”, and the answer is worded that way on purpose.

Fields that appear only on a flow screen, only inside a Lightning component’s markup, or only as a column of a related list on another object’s layout count as used. If you upgraded from an older release, run refresh once so those references are in your snapshot.

Ask it like this

Use your own object and field names. If a name matches more than one thing, it asks which one you mean.

  • Can I delete the Amount field on Invoice?
  • What breaks if I delete Account.Legacy_Code__c?
  • Is it safe to remove the Region picklist on Opportunity?
  • Is this deployment risky? It deletes three fields.

What it checks, and what it can’t see

Checks

  • Formulas and roll-ups that use the field
  • Flows, workflow and validation rules that read or set it
  • Apex that reads or writes it, from the parsed source
  • Page layouts and permissions that include it, including columns of related lists on other objects’ layouts
  • Flow screens that show or edit it, and Lightning component markup that binds it
  • Reports, when your refresh pulled them (the most-used 500 by default)
  • Name-only mentions in Apex strings and OmniStudio paths, listed separately for you to check

Can’t see

  • Field names put together piece by piece at run time in Apex
  • Managed-package code, integrations and API loads
  • Anything changed in the org since your last refresh
  • Kinds of metadata your refresh didn’t pull. The answer lists them as “not checked”, never “none”
For developers: the tools behind this

Your assistant picks these from the plain-language question. You never have to name them.

Questions

Isn’t Salesforce’s “Where is this used?” button enough?

It is a good start, but it works one field at a time and misses some references, such as field names in dynamic Apex and some formula and Lightning uses. sf-intelligence answers from the whole metadata snapshot at once and tells you which kinds of metadata it did and didn’t check.

Does it delete the field for me?

No. sf-intelligence is read-only. It tells you what depends on the field and what to change first. The delete stays your job, in Setup or in a deployment.

What does “not checked” mean in an answer?

Those kinds of metadata weren’t in your snapshot, so the tool can’t say whether they use the field. It says so instead of implying they don’t. Widen your refresh to include them, or check those by hand.