Overview
The Excel NOT function changes a logical or Boolean result from FALSE to TRUE or TRUE to FALSE. When the NOT function is passed an expression that evaluates as TRUE, it will return FALSE. When the NOT function is passed an expression that evaluates as FALSE, it will return TRUE.
Syntax
=NOT(logical)
Arguments
logical – A value or expression that can be evaluated to TRUE or FALSE.
Version
Excel 2003
Purpose
The Excel NOT function returns TRUE when given a FALSE value, and FALSE when given a TRUE value. The NOT function only works when the expression it is evaluating is either TRUE or FALSE.
=NOT(logical)
Examples
In this first example, we can see how the NOT function essentially changes all TRUE values to FALSE and all FALSE values to TRUE:
The formula we have in cell D4 (and is applied to the adjacent cells in column D) is:
=NOT(B4)
In the example above, we can see that every value in column D shows the opposite of what is shown in column B. Where cell B4 is ‘FALSE’, cell D4 is ‘TRUE’, and so on for the adjacent cells.
A common use for the NOT function is the reverse the result of another function. Let’s see what that looks like below:
The formula we have in cell D4 (and is applied to the adjacent cells in column D) is:
The ISNUMBER function returns the value ‘TRUE’ when a value is number. In the example above, we use the NOT function to reverse the logic, which is why the result in cell D4 is ‘FALSE’. We can go a step further to clean up our data, which involves using an IF statement as well:
The formula we have in cell D4 (and is applied to the adjacent cells in column D) is:
By reversing the result of the ISNUMBER function, we are able to use an IF statement to single out the values that are not numbers. The NOT function can be used in a wide variety of situations, where logic needs to be reversed. This is common with functions such as: ISTEXT, ISNUMBER, ISBLANK and ISFORMULA. The NOT function is also typically paired with the IF function as we saw above, which allows the user to have more control over the output.
Notes
- The input to the NOT function must be a logical value, otherwise a #VALUE! error will occur
Author
Kyle Stott
Certified Microsoft Excel Expert
Kyle has worked professionally with Microsoft Excel for over a decade and has been consulting on and teaching best practices in Microsoft Excel to over 400 companies across 30+ countries.
Want to learn more?
Join My Excel Academy Today!
This All-Access Pass Includes:
- Access to All My Excel Academy Courses
- 20+ hours of on-demand video
- 1-on-1 instructor support
- Mobile learning supported
- Frequently updated content
- Learn at your own pace
- 500+ practice problems
- Certificate of completion
30-Day Money-Back Guarantee
Want to learn more?
Join My Excel Academy Today!
All-Access Pass Includes:
- Access to All My Excel Academy Courses
- 20+ hours of on-demand video
- 1-on-1 instructor support
- Mobile learning supported
- Frequently updated content
- Learn at your own pace
- 500+ practice problems
- Certificate of completion
30-Day Money-Back Guarantee
Want to learn more?
Join My Excel Academy Today!
30-Day Money-Back Guarantee
This all-access pass includes:
- Access to all My Excel Academy Courses
- 20+ hours of on-demand video
- 1-on-1 instructor support
- Mobile learning supported
- Frequently updated content
- Learn at your own pace
- 500+ practice problems
- Certificate of completion
Don’t hesitate – join now!