.not() is the complement of .filter(): it removes elements that match the given selector, element, or function from the matched set. Think of it as a subtraction operation on your jQuery collection.
Selector Argument
Passing a selector string removes all elements in the set that match that selector. This is equivalent to the CSS :not() pseudo-class but operates on an existing jQuery collection rather than querying the document from scratch.
Function Argument
Like .filter(), .not() also accepts a function. Return true to exclude the element. This lets you express complex exclusion criteria involving computed values or data attributes.
.not('.disabled')— exclude disabled elements.not(this)— exclude the element referenced bythis.not(function(){ return ... })— dynamic exclusion
A common use of .not(this) is in hover effects for sibling groups: when the user hovers one item, dim all the others by applying a class to the sibling set after excluding the hovered element.