# Nested !important tags

**URL:** <https://forum.kirupa.com/t/nested-important-tags/262578>\
**Category:** Uncategorized\
**Created:** [June 7, 2008, 6:27am UTC](https://forum.kirupa.com/t/nested-important-tags/262578 "2008-06-07T06:27:20Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![sekasi](https://avatars.discourse-cdn.com/v4/letter/s/5f8ce5/32.png) [@sekasi](https://forum.kirupa.com/u/sekasi)\
**Post date:** [June 7, 2008, 6:27am UTC](https://forum.kirupa.com/t/nested-important-tags/262578/1 "2008-06-07T06:27:20Z")

</div>

To make the post short, I just want some confirmation;

Nested !important tags on the same property always take priority the ‘deeper’ they are in the nest right?

ie;

#block {  
color: #0A0A0A !important;  
};  
#block #block2 {  
color: #FFFFFF !important;  
}  
#block #block2 #block3 {  
color: #999999 !important;  
}

So if there’s text inside block3 that is nested, it’ll get #999999 rite? Just trying to troubleshoot here, want to rule this factor out :kir:

---

<div class="post-metadata">

**Author:** ![simplistik](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/simplistik/32/7747_2.png) [@simplistik](https://forum.kirupa.com/u/simplistik)\
**Post date:** [June 7, 2008, 2:04pm UTC](https://forum.kirupa.com/t/nested-important-tags/262578/2 "2008-06-07T14:04:06Z")

</div>

wtf? why would you do it that way? if you get rid of important you’ll get the same result, I fail to see what you’re attempting to accomplish. of course block3 will be #999999 not because of the important flag, but because that’s where it’s at in the cascade.

---

<div class="post-metadata">

**Author:** ![Esherido](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/esherido/32/2158_2.png) [@Esherido](https://forum.kirupa.com/u/Esherido)\
**Post date:** [June 7, 2008, 8:30pm UTC](https://forum.kirupa.com/t/nested-important-tags/262578/3 "2008-06-07T20:30:39Z")

</div>

Personally, I think !important tags are unnecessary and that a good designer shouldn’t have to use them unless absolutely necessary. Especially considering the fact that a bunch of !important tags in a stylesheet would bring up its file size.

---

<div class="post-metadata">

**Author:** ![Jeff\_Wheeler](https://avatars.discourse-cdn.com/v4/letter/j/59ef9b/32.png) [@Jeff\_Wheeler](https://forum.kirupa.com/u/Jeff_Wheeler)\
**Post date:** [June 7, 2008, 9:06pm UTC](https://forum.kirupa.com/t/nested-important-tags/262578/4 "2008-06-07T21:06:57Z")

</div>

That is correct.

It’s good to understand the specificity rules and cascading properties of [font=monospace]!important[/font] which are described on the [CSS specification](http://www.w3.org/TR/REC-CSS2/cascade.html).
