CSS Specificity Calculator
Enter any CSS selector and instantly see its specificity score broken down by inline styles, IDs, classes/attributes/pseudo-classes, and elements/pseudo-elements. Compare multiple selectors side-by-side to debug cascade conflicts.
Ctrl+Enter to run · Ctrl+K to switch tools · Recent button shows input history
Let AI do the hard part. Fix broken HTML, convert to email-safe HTML, or clean up any markup in one click — 3 free AI runs per day, no account needed.
Try the AI HTML FixerFAQ
What is CSS specificity?
Specificity is the algorithm browsers use to decide which CSS rule wins when multiple rules target the same element. It's scored as four numbers (a,b,c,d) where a=inline, b=IDs, c=classes, d=elements.
Why does my CSS not apply?
Usually a more specific selector is overriding it. Use this tool to compare two selectors and see which one wins.