This page is Almost Ready

Notice: The WebPlatform project, supported by various stewards between 2012 and 2015, has been discontinued. This site is now available on github.



Gets the CSS Rule that imported the style sheet, if any.

Property of css/cssom/styleSheetcss/cssom/styleSheet


Note: This property is read-only.

var rule = stylesheet.ownerRule;

Return Value

Returns an object of type DOM NodeDOM Node

Of type CSSRule. Returns a CSSImportRule or null.


If the style sheet comes from an @import rule, the ownerRule property will contain a CSSImportRule object, and the ownerNode property will be null. If the style sheet comes from a link, the ownerRule property will be null, and the ownerNode will contain the node.

Related specifications

DOM Level 2 Style

See also

Related pages