Print this page

How do I use validation rules to prevent users from modifying closed won/lost Opportunities?

Knowledge Article Number 000005286

Some organizations do not want users to modify opportunities once they have been closed, regardless of whether they are "won" or "lost".


Here are two approaches to preventing users from editing Closed or Closed Won opportunity records.  The examples below use example profile IDs in the formula syntax.  Note that the IDs used below will vary by organization.

** CLOSED **
The following Validation Rule will only allow users edit closed opportunities if they are assigned to a Profile ID listed (example is System Administrator "00et0000000q111" or Sales VP "00et0000000q222") will be able to edit the Opportunity.

Validation rule syntax:

PRIORVALUE( IsClosed ) = True,
$Profile.Id = "00et0000000q111",
$Profile.Id = "00et0000000q222"))

The following Validation Rule will only allow users edit closed/won opportunities if they are assigned to single profile ID below (example is System Administrator or "00et0000000q111") will be able to edit the Opportunity.

ISPICKVAL(PRIORVALUE(StageName),"Closed Won"),
NOT($Profile.Id = "00et0000000q111")


  • This rule will allow any user into the Edit mode, but will prevent Save, showing Validation Rule error message upon save
  • This rule will not allow a new "Add Product" on the Opportunity Line Items, you unless you are the Profile ID listed. For non System Admins, the Validation Rule will trigger on the "Save" page of the "Add Product" process
  • This rule will not prevent the "Edit" of existing Opportunity Line Items, for both System Admins and other Profile users

Other examples of useful validation rules can be found in the Help and Training here: Examples of Validation Rules

promote demote