HTML embed tag

HTML <embed> tag helps in integrating the plugin or external non-HTML application.

<embed src="files/demo.html" width="80%" height="400px" />
</>

The above example embeds a an HTML page in the page.

src attribute contains the address of the page to be embeded.

Tag Uses

Specific uses of <embed> tag

Its main use is to integrate applications or interactive content.

Tag omission

It is self-closing tag i.e no end tag (</embed>).

Global Attributes

All the global attributes are applicable on the embed element.

Tag Attributes

Attributes that are applicable to <embed> tag
src

src attribute represents the location of the external resource.

<embed src="address of external resource/URL">
type

type attribute represents the type of external embeded content.

<embed src="address of external resource/URL" type="application/pdf" >
width

width attribute defines the horizontal dimension.

<embed src="Location of embeded resource" width="an integer">
height

height defines the vertical dimension.

<embed src="URL" height="an integer">anchor text</a>


Was this article helpful?