The ownerNode property of the StyleSheet interface returns the node that associates this style sheet with the document.


objRef = stylesheet.ownerNode 


  <link rel="StyleSheet" href="example.css" type="text/css" />
   function stilo() {
   <button onclick="stilo()">ss</button>
// Displays "object HTMLLinkElement"


For HTML, ownerNode may be the corresponding LINK or STYLE element. For XML, it may be the linking processing instruction. For style sheets that are included by other style sheets, the value of this attribute is NULL.


DOM Level 2 Styles - STYLESHEET

Browser compatibility

Update compatibility data on GitHub
ChromeEdgeFirefoxInternet ExplorerOperaSafariAndroid webviewChrome for AndroidEdge MobileFirefox for AndroidOpera for AndroidSafari on iOSSamsung Internet
ownerNodeChrome Full support 1Edge Full support 12Firefox Full support YesIE ? Opera Full support YesSafari Full support YesWebView Android Full support YesChrome Android Full support YesEdge Mobile ? Firefox Android Full support YesOpera Android Full support YesSafari iOS Full support YesSamsung Internet Android ?


Full support  
Full support
Compatibility unknown  
Compatibility unknown

Document Tags and Contributors

Last updated by: mdnwebdocs-bot,