This page is part of the CSS3.info CSS selectors test. See more info on CSS3 selectors.

  1. :not(#id) {
    }
    
    <div></div>

    The CSS selector should match the div element, because it is not a match for the #id selector

  2. :not(.class) {
    }
    
    <div></div>

    The CSS selector should match the div element, because it is not a match for the .class selector

  3. :not(#id) {
    }
    
    <div id='id'></div>

    The CSS selector should not match the div element, because it is a match for the #id selector

  4. :not(.class) {
    }
    
    <div class='class'></div>

    The CSS selector should not match the div element, because it is a match for the .class selector