<applet>

The <applet> element was used to embed Java applets into an HTML page. It has since been deprecated and removed from the HTML specification. This tag should no longer be used as browsers no longer support it.

Syntax

<!-- This is no longer supported -->
<applet code="url of Java class file">
Text displayed when no Java runtime is available.
</applet>

A code attribute supplied the URL for a given Java class file. It could also use common attributes like width and height.

The <applet> element included zero or more <param> tags to pass parameters on to the Java applet. Its functionality is now incorporated into the <object> tag.

<!-- This is no longer supported -->
<applet code="url of Java class file">
<param name="name of parameter" value="value of parameter" />
Text displayed when no Java runtime is available.
</applet>

Example

<!-- This is no longer supported -->
<applet code="myApplet.class" height="300" width="300">
<param name="input" value="This is deprecated HTML" />
This browser doesn't support Java applets.
</applet>
Edit this page on GitHub

Contributors

Interested in helping build Docs? Read the Contribution Guide or share your feedback form.

Learn HTML on Codecademy