Validation rules are the silent contract between admins and users. They are supposed to be the loudest line of defense against bad data — and in mature orgs they're also the most overgrown, the most under-tested, and the most likely to silently fail. A rule with a typo in its Error Message field tells the user nothing when a save fails. A rule disabled in 2022 to ship a campaign is still disabled in 2026, sitting next to eight new ones. A rule that worked in the UI starts mysteriously rejecting data the moment your integration partner flips on the Bulk API 2.0 suppression flag.

This guide is the admin's end-to-end validation rules audit. It covers why inactive rules accumulate after org changes and how to inventory them with Setup and SOQL, what blank or generic error messages do to the silent-failure rate, where validation gets bypassed in API and integration contexts versus UI saves, the Setup and Workbench checks you can run from a browser today, and when it's time to escalate to a Founding Audit.

30–50% of validation rules in mature Salesforce orgs are inactive or reference deleted metadata. That's not a guess — it's what sustained org audits consistently surface. Each inactive rule is a relic still consuming review attention, and each rule with a weak error message is a save that fails without telling the user why.

1. Why Inactive Validation Rules Accumulate (and How to Inventory Them)

Every org change is a chance to leave a validation rule behind. A new object is added, but the old rule that referenced the renamed field isn't migrated — it's deactivated "for now" so the deployment doesn't break, and then nothing cleans it up. A record type is retired, but the rule that gated stage progression on that record type stays in place, now silently inactive because no records hit the criteria. A marketing pilot rolls out, three rules are turned off to make the upload work, and the post-mortem never flips them back on.

The result is that mature orgs accumulate inactive rules faster than they document them. Setup shows each rule with an Active checkbox, but the Setup list — paginated, unfiltered, no export — doesn't give admins a clean inventory of what's actually firing. The first move in any validation rules audit is getting a real list of every rule, active or not, and finding the dead weight.

Option A: Setup → Object Manager → Validation Rules

Open Setup → Object Manager, pick an object (start with Account, Opportunity, Contact, and Lead), and click Validation Rules. Each row shows the rule name, a description, the Active checkbox, and the error message. Filter by the Active column manually: every unchecked row is your inactive-rule candidate. Repeat per object — the tooling doesn't aggregate this view across objects.

Option B: Workbench SOQL over the EntityDefinition + ValidationRule metadata

For an org-wide inventory, the right move is a metadata-API query. Open Workbench and switch to the metadata API, then run a query that lists every ValidationRule across every object with its active flag and active flag for the underlying metadata:

SELECT EntityDefinition.QualifiedApiName, ValidationName, Active, ErrorMessage, ErrorConditionFormula, LastModifiedDate
FROM ValidationRule
ORDER BY Active ASC, EntityDefinition.QualifiedApiName ASC

Each row tells you the object's API name, the rule's developer name, whether the rule is active, the ErrorMessage string shown to users, and the full ErrorConditionFormula that gates the rule. Sort by Active ASC — every Active = false row is your candidate cleanup list. The query covers every rule in the org in a single pass, which is what the Setup walk gives you only after dozens of screen loads.

For orgs with hundreds of rules, the same metadata API call can be paired with a programmatic unwinder: pull every .validationRule-meta.xml via sf project retrieve start -m ValidationRule:*, then grep each file for <active>false</active>. That gives you the per-file audit trail and makes deactivation rollups mechanical.

2. Missing or Empty Error Messages — The Silent Failure Mode

The second pillar of any validation rules audit is the error-message review. A rule that fires with no message (or with a message the admin typed and forgot to wire into the Error Message field) becomes a silent failure: the user clicks Save, the save is rejected by the platform, and the only signal is a generic inline error at the top of the layout. From the user's perspective, the rule "broke my save" with no further explanation. From the admin's perspective, the same rule is "fine, I see it in Setup." The two views never connect, and the underlying data integrity problem gets filed as "user error."

Three failure modes are common: the Error Message field is literally empty (the rule rejects saves with no inline message at all), the Error Message is a generic stub like "Invalid value" or "Error" (which doesn't tell the user what to do), or the rule fires only on a Save-button click path while a parallel bulk path silently bypasses it (covered in Section 3 below).

Detection path 1: Setup walk

Open every rule in Setup → Object Manager → Validation Rules. Read the Error Message column. Any row that reads (blank), "Invalid", "Error", "Please correct", or any other generic stub is a candidate for message-template replacement.

Detection path 2: Bulk export with the Salesforce CLI

For orgs with hundreds of rules, retrieval via the Salesforce CLI gets you every ValidationRule as a .validationRule-meta.xml in under a minute:

sf project retrieve start -m ValidationRule:*

Then grep across the retrieved files for rules with empty or generic error messages:

grep -rl '<errorMessage></errorMessage>\|<errorMessage>Invalid</errorMessage>\|<errorMessage>Error</errorMessage>' objects/

Each hit is a rule whose failure path is silently opaque to the user. The fix is a standard template — something like "[Field] must be set before [action]; see [doc link] for examples." — wired into the rule's Error Message field. Standard messages turn the rule from a friction point into an instruction.

The cost of "Valid Value Required"

A custom Required_Date__c rule on the Quote object has an Error Message that reads exactly "Valid value required." A rep tries to save a Quote without the date. The save fails silently — the user sees only the generic error, has no idea which field is the problem, and escalates to the admin. The admin opens the Quote, sees the same generic error, and has to manually trace the rule to figure out that Required_Date__c is the missing field. Every save attempt costs 15 minutes of back-and-forth.

Replace "Valid value required" with "Required Date must be set before sending the Quote to the customer — see the Quote playbook for the standard format." and the same failure path becomes self-service: the rep sees the field name, the action they need to take, and a link to the doc. The error stops being a support ticket and starts being an instruction.

The right pattern is a small library of message templates approved by the admin lead, indexed by the rule's category (missing-field, format, length, cross-object, hierarchy-sensitive), and reused across every new rule. The Validation Rule Auditor reads your org's rule metadata, surfaces every empty or generic Error Message, and ranks them by the rule's blast radius (how many records/objects the rule gates).

3. Bypass Patterns — Where Validation Gets Skipped (API vs UI)

The third pillar of the audit — and the one admins most often miss — is the bypass surface: the set of save paths where validation rules do not fire. Salesforce validation rules run on every UI save path, on standard REST API save paths, and on Apex triggers called from those paths. But there are three well-known save paths where rules are routinely skipped, and each one is a potential data-integrity gap that admins don't see until an integration partner reports dirty records.

Path A: Bulk API 2.0 with explicit validation suppression

Bulk API 2.0 jobs accept a job-level option called ValidationRule: false. When set, every validation rule in the destination org is suppressed for the duration of the ingestion. ETL pipelines and migration tools sometimes toggle this to make ingestion faster or to side-step rules that were designed for a UI workflow but reject bulk-shaped data. The result is that integration records skip validation entirely and land in the org dirty.

Path B: Apex Database.insert(records, false) partial-success mode

When an Apex call uses Database.insert(records, false) (or allOrNone = false), the call attempts to insert every record and returns the failures rather than rolling back the whole batch. Under allOrNone = false, validation rules do still fire — but the records that satisfy the rule and the records that fail are mixed in the same return value. The practical issue is admin visibility: failures are buried in Database.Error[] arrays and often only the integration team sees them. If your Apex is using Database.insert(records, true) (allOrNone), validation runs but a failure aborts the batch — which produces a different shape of partial-success visibility problem.

Path C: Declarative data imports (Data Loader, Data Import Wizard, import wizards)

Salesforce's declarative data import tools have an option that disables validation rules for the import run. Data Loader exposes this through field-mapping options; the Data Import Wizard exposes it through Settings → Import. When toggled off, validation rules are bypassed for every row in the file. Imports run faster, dirty rows land in the org, and admins don't see the rule suppression unless they audit the import history.

Why this matters for data integrity

The danger of bypass patterns isn't that admins use them — it's that admins and integration partners reach for them without coordinating on what gets accepted. A Data Loader import that toggles off validation can create 10,000 Leads with empty Email in a single run. The Leads show up in reports with no Email, distort campaign attribution, and silently break any downstream Flow that gates on Lead.Email != null. The "fix" is to remember the suppression flag was set — which nobody does six months later.

The right pattern is a documented import policy that names the rules exempt for each import path, paired with an explicit post-import cleanup (a Flow that runs an equivalent formula check and routes dirty rows to a queue). For orgs that ingest from multiple sources, this is the topic the dashboard-signals engine's missing_values signal was built to surface.

For orgs that want a read on their current bypass exposure, the right first move is an import-history audit: a Workbench query to DataImportBatch and a manual scan of any scheduled-ETL jobs that pass --no-validation-style flags. Then a linked-org scan via the Validation Rule Auditor profiles which rules are exposed to which bypass paths.

4. Five Setup/SOQL Checks You Can Run From a Browser

You don't need a paid audit tool to find the highest-impact validation rule problems. Five checks, each one runnable from Workbench or Setup in under an hour:

Check 1: All inactive rules, org-wide

How to find it: Open Workbench, switch to the metadata API, and run the ValidationRule query from Section 1 sorted by Active ASC. Every Active = false row is a candidate. Cross-reference the rule's EntityDefinition.QualifiedApiName to confirm the object still exists; if the object was deleted, the rule is metadata garbage and should be hard-deleted rather than left deactivated.

What good looks like: A small number of Active = false rules, each one tagged with a written justification (a deprecation plan, a migration in flight, a documented "off for the Q4 promo"). Any rule that's been inactive for two quarters without a documented reason is cleanup-ready.

Check 2: Empty or generic ErrorMessage strings

How to find it: Run sf project retrieve start -m ValidationRule:* from your authenticated CLI, then grep each file for empty or generic errorMessage nodes:

grep -rln '<errorMessage>\s*</errorMessage>\|<errorMessage>.*\(Invalid\|Error\|Valid\)' objects/ | sort

Each hit is a rule whose failure shows the user a generic or missing message. The fix is message-template replacement (Section 2).

What good looks like: Every rule's errorMessage is a full sentence that names the field, names the constraint, and points to documentation. Generic stubs like "Valid value required" are replaced with explicit "[Field] must satisfy [constraint]; see [doc]."

Check 3: Bypass-aware ValidationRule.Metadata introspection

How to find it: Pull every ValidationRule metadata file and grep for bypass or bypassMetadataTypes nodes. Active rules that mention a bypass — e.g. an $User check that exempts an integration user — are deliberately creating a partial-bypass path and should be documented in your import policy. Inactive rules that mention a bypass are doubly suspect: a rule that exempts everything is structurally equivalent to no rule at all.

What good looks like: Every bypass-exempt scope is documented in your import policy and reviewed quarterly. Stale bypasses (rules that exempt an integration user whose account has since been disabled) are removed.

Check 4: $Profile.Name / $UserRole.Name references in ErrorConditionFormula

How to find it: Run a Workbench metadata-API query that returns ErrorConditionFormula for every rule, then grep for $Profile.Name or $UserRole.Name tokens. Each hit is a rule whose behavior is bound to a profile or role string, not to a permission-set-based check. Profile and role names are fragile (renamed during mergers, on persona changes, on org migrations), so their use in a rule formula is a smell.

grep -rn '\$Profile\.Name\|\$UserRole\.Name' objects/*/validationRules/*.xml | sort

What good looks like: Rules gate on permission-set membership ($Permission.MyPermissionSet) or on record-ownership fields, not on profile/role name. Where a profile-gate is genuinely required (e.g. a transitional rule during a role-migration), the rule is documented with a deprecation date.

Check 5: Rules referencing deleted fields or retired record types

How to find it: Pull every ValidationRule metadata file. For each rule, extract every field API name referenced in ErrorConditionFormula and cross-reference against the current EntityParticle catalog. Any rule that references a field API name not in the catalog is broken — its formula will fail on save or evaluate to an empty condition. Same approach for record-type developer names.

What good looks like: Every field API name and record type referenced in any rule's formula still exists in the org's metadata. Broken-reference rules are either fixed (formula updated to reflect the new field) or deactivated with a written deprecation note.

Run the Full Validation Rule Scorecard in Minutes

The Validation Rule Auditor retrieves every rule's metadata, flags inactive rules and broken references, surfaces empty or generic error messages, and ranks the highest-risk rules first. No Salesforce credentials required for the CSV-based scan.

5. From Manual Audit to Founding Audit

The five checks above catch the highest-impact problems — inactive rules, blank error messages, broken formula references, profile-bound bypasses, and stale data-import suppression flags. For an org with fewer than 50 validation rules, you can complete the whole audit in a half-day.

For orgs with hundreds of validation rules, the bottleneck is no longer detection — it's prioritization. Which of the 80 inactive rules are safe to hard-delete vs. should be reactivated? Which empty error messages are on rules that fire dozens of times per day (and so cost the most user time) vs. rules that are essentially dormant? Which rules are exposed to the Bulk API 2.0 ingestion path (and so are the ones integration partners are quietly skipping)?

A Founding Audit runs the full scoring, prioritizes the findings by active blast radius (which rules are firing today, which bypass paths are exercised by live integrations, which error messages are showing up in user support tickets), and surfaces the fixes in the order they'll have the highest data-integrity return. It's the same step you'd run manually — automated, repeatable, and tied to findings the team can action in one sprint.

Frequently Asked Questions

How does this differ from Salesforce Validation Rule Conflicts?
The conflicts guide covers opposing-logic rule pairs — two rules on the same object whose formulas contradict each other (e.g. one rule requires Region != null, another requires Region = null). This pillar is broader: inactive rules accumulating after org changes, missing error messages causing silent failures, and bypass patterns where validation gets skipped for API and integration contexts. The two guides share an underlying rule inventory but score different failure modes.

How often should I run a validation rules audit?
Every quarter for actively-maintained orgs, every six months for stable orgs. Run it immediately after any major org change — a release that adds 5+ new rules, a sandbox promotion that includes rule diffs, an integration onboarding that introduces a new bypass path, or a consulting engagement that touched validation logic.

Can I run a validation rules audit without a Salesforce administrator login?
Yes. The metadata-API query in Check 1 and the ruled-XML retrieval pattern in Check 2 both work for read-only audit access. Any admin with read-only org access can produce the metadata export the audit runs on. For org-scale audits that also score bypass exposure and error-message replacement impact, a connected-org diagnostic is faster — but the XML path works for consultancies that can't be granted full org access.

What's the most common validation rule issue you find?
Empty or generic error messages. Across sustained org audits, roughly a third of rules have either no errorMessage or a generic stub. Each is a friction point that costs a few minutes per failure and adds up — a rule that fires 200 times a month with a generic message is a subtle tax on every rep. The fix is mechanical (template replacement) but the rollout is organizational: every dev who writes a rule has to remember to use the template, and every old rule has to be retro-edited.

Why do I need a rule inventory if I already have Salesforce Optimizer?
Salesforce Optimizer surfaces rules that are "inactive or empty condition," but it's a static snapshot that misclassifies several important failure modes. It doesn't distinguish inactive-by-design (a documented deprecation) from inactive-by-neglect (a stale relic). It doesn't score error-message quality. It doesn't surface bypass-exposure routes. The rule inventory from this audit is the foundation for prioritization — without it, every "fix" is guesswork about order of operations.

Continue Reading

Related audits

Explore the next scoped review

This guide provides context for a scoped conversation. The Org Health Assessment offers a broader review, while the Salesforce Flow & Automation Assessment focuses on validation and automation business-logic interactions. Scope and the final quote are confirmed after intake.