HTML defer Attribute

❮ HTML Attributes


<script src="demo/demo-async.js" defer></script>


The defer attribute specifies that the browser might defer execution of the script enclosed by the <script> element.


Standard Syntax

HTML: <element defer>

XHTML: <element defer="defer">

Browser Support


Applies to:

The defer attribute can be used on the following element:

Element Attribute
<script> defer

Attribute Values

Value Description
defer This is a boolean attribute, the presence of a boolean attribute on an element represents the true value, and the absence of the attribute represents the false value.
❮ HTML Attributes