HTML Tutorial

HTML Tag: <embed>

Understanding the <embed> Tag

The <embed> tag allows you to embed interactive content, such as videos, audio files, and applets, into an HTML document.

Attributes of <embed>

Attribute Description
src Specifies the URL of the file to be embedded
type Specifies the MIME type of the embedded content
width Sets the width of the embedded object in pixels
height Sets the height of the embedded object in pixels
pluginspage Links to a page that contains any necessary plugins for viewing the embedded content

Examples with <embed>

  1. Embed a video:
<embed src="video.mp4" type="video/mp4">
  1. Embed an audio file:
<embed src="audio.mp3" type="audio/mpeg">
  1. Embed an applet:
<embed src="applet.jar" type="application/x-java-applet">

Exploring the <embed> tag

<!DOCTYPE html>
<html>
<body>

<p>Embedded Video:</p>
<embed src="video.mp4" type="video/mp4" width="320" height="240">

</body>
</html>