IFrame height property
Frame/IFrame Object
Definition and Usage
The height property sets or returns the value of the height attribute of an iframe element.
The height attribute specifies the height of the iframe (in pixels or as a percentage).
Syntax
iframeObject.height=
value
The height property can have the following values:
| Value | Description |
|---|---|
| pixels | The height can be specified in pixels (e.g. "100px" or "100") |
| % | The height can be specified as a percentage (e.g. "20%") |
Browser support





All major browsers support the height property
Example
Example
Change the height and width of the iframe:
Try it »
Frame/IFrame Object