HTMLIFrameElement

The interface for <iframe>. Extends HTMLElementElement.

Reflected properties

All setters are guarded and throw NoModificationAllowedError on a read-only document.

Property Attribute Type Notes
src src string Reflects verbatim — no base-URL resolution.
srcdoc srcdoc string Reflects the content attribute verbatim.
name name string Reflects the content attribute verbatim.
width width string Reflects the content attribute verbatim.
height height string Reflects the content attribute verbatim.
allow allow string Reflects the content attribute verbatim.
loading loading enum Keywords: lazy · eager. Missing → "eager"; invalid → "eager".
referrerPolicy referrerpolicy enum Keywords: "" · no-referrer · no-referrer-when-downgrade · same-origin · origin · strict-origin · origin-when-cross-origin · strict-origin-when-cross-origin · unsafe-url. Missing → ""; invalid → "".

See also