Some organizations do not want Users to modify Opportunities once they have been closed, regardless of whether they are 'won' or 'lost.' This article shows two Salesforce validation rule approaches for preventing edits to closed Opportunity records.
This article explains how to create validation rules in Salesforce that prevent Users from editing Closed or Closed Won Opportunity records unless they are assigned to a specific Profile. The examples below use example Profile IDs in the formula syntax. Note that the IDs used below will vary by organization.
The following validation rule allows only Users who are assigned to one of the listed Profile IDs (for example, System Administrator "00et0000000q111" or Sales VP "00et0000000q222") to edit closed Opportunities.
Validation rule syntax:
AND(
PRIORVALUE( IsClosed ) = True,
NOT(OR(
$Profile.Id = "00et0000000q111",
$Profile.Id = "00et0000000q222"))
)
The following validation rule allows only Users who are assigned to the single Profile ID below (for example, System Administrator "00et0000000q111") to edit Closed Won Opportunities.
Validation rule syntax:
AND(
ISPICKVAL(PRIORVALUE(StageName),"Closed Won"),
NOT($Profile.Id = "00et0000000q111")
)
000385070

We use three kinds of cookies on our websites: required, functional, and advertising. You can choose whether functional and advertising cookies apply. Click on the different cookie categories to find out more about each category and to change the default settings.
Privacy Statement
Required cookies are necessary for basic website functionality. Some examples include: session cookies needed to transmit the website, authentication cookies, and security cookies.
Functional cookies enhance functions, performance, and services on the website. Some examples include: cookies used to analyze site traffic, cookies used for market research, and cookies used to display advertising that is not directed to a particular individual.
Advertising cookies track activity across websites in order to understand a viewer’s interests, and direct them specific marketing. Some examples include: cookies used for remarketing, or interest-based advertising.