You are here: Reference > JavaScript > client-side > HTML DOM > properties > status (window)

status property (window)

Browser support:
Sets the message in the status bar or retrieves the previously specified value.
The status bar is used by the browser to display additional information. For example, if the mouse is over an anchor element, the browser displays the destination URL of the anchor element in the status bar. When no additional information needs to be displayed, the status bar contains the default message. With the defaultStatus property the value of the default message can be modified.
To modify the currently displayed message in the status bar, use the window.status property.
Note that in Firefox, changing the text in the status bar is not allowed by default, the dom.disable_window_status_change setting (you can find it on the about:config page) must be set to false by the user to allow scripts to change it.


You can find the related objects in the Supported by objects section below.
This property is read/write.

Possible values:

String that specifies the message or retrieves the previously specified message.
Default: false.

Example HTML code 1:

This example illustrates the use of the status property:
    <script type="text/javascript">
        function UpdateStatusBar (over) {
            if (over)
                window.status = "The mouse is over the text.";
                window.status = window.defaultStatus;

        function ChangeDefStatus () {
            window.defaultStatus = "Default status bar message.";
    <div onmousemove="UpdateStatusBar (true);" onmouseout="UpdateStatusBar (false);">
        A message is visible in the status bar while moving the mouse over this text.
    <br /><br />
    You can change the default message in the status bar with this button:
    <button onclick="ChangeDefStatus ();">Change default status</button>
    <br /><br />
    <a href="#">If the mouse is over this anchor, the browser displays the destination URL in the status bar.</a>
Did you find this example helpful? yes no

Supported by objects:

Related pages:

External links:

User Contributed Comments

Post Content

Post Content