W3Schools.com

Document readyState Property

Document Object Reference Document Object

Definition and Usage

The readyState property returns the (loading) status of the current document.

This property returns one of four values:

  • uninitialized - Has not started loading yet
  • loading - Is loading
  • interactive - Has loaded enough and the user can interact with it
  • complete - Fully loaded

Syntax

document.readyState


Browser Support

Internet Explorer Firefox Opera Google Chrome Safari

The readyState property is supported in all major browsers.


Example

Example

Return the loading status of the current document:

<html>
<body>

Loading status:
<script type="text/javascript">
document.write(document.readyState);
</script>

</body>
</html>

Try it yourself »


Document Object Reference Document Object
WEB HOSTING
Best Web Hosting
PHP MySQL Hosting
Best Hosting Coupons
UK Reseller Hosting
Cloud Hosting
Top Web Hosting
$3.98 Unlimited Hosting
Premium Website Design
WEB BUILDING
XML Editor - Free Trial!
FREE Website BUILDER
Best Website Templates Top CSS Templates
CREATE HTML Websites
EASY WEBSITE BUILDER
W3SCHOOLS EXAMS
Get Certified in:
HTML, CSS, JavaScript, XML, PHP, and ASP
W3SCHOOLS BOOKS
New Books:
HTML, CSS
JavaScript, and Ajax
STATISTICS
Browser Statistics
Browser OS
Browser Display
SHARE THIS PAGE