Latest web development tutorials

HTML DOM readyState property

Document Object Reference Document Object

Definition and Usage

readyState property returns the status of the current document (Loading ......).

This property returns the following values:

  • uninitialized - has not yet begun loading
  • loading - Loading
  • interactive - has been loaded, the user can begin to interact with the document
  • complete - Loading completed

grammar

document.readyState


Browser Support

Internet ExplorerFirefoxOperaGoogle ChromeSafari

All major browsers support readyState property


Examples

Examples

Returns the current state of the document loaded:

<html>
<body>

Loading status:
<script>
document.write(document.readyState);
</script>

</body>
</html>

try it"


Document Object Reference Document Object