So Long and Thanks for All the Applets
Phil Race on December 3, 2025
The entire java.applet package has been removed from JDK 26, which will release in March 2026.
JDK 25 (an LTS release depending on your vendor) is the last Java SE version to include the java.applet API.
This was done under JEP 504: Remove the Applet API and the reasons behind the removal as well as its timing deserve an explanation.
A Bit of Background About Applets
The java.applet.Applet class was a foundational class of the Java platform from the very beginning, shipping with JDK 1.0 in 1996.
At the time, the majority of uses of Java revolved around applets, which were small programs that would run in a shared virtual machine, typically embedded in one of the browsers of the day (predominantly Netscape Navigator and Internet Explorer via the Java Browser Plugin).
They added a level of capability impossible with early versions of HTML.
The lifecycle of these small applets was determined by the java.applet.Applet APIs.
Java Applets were downloaded from a web server just like HTML and if the <APPLET> tag was supported, the applet would run because your locally installed Java Plugin would bridge the platform-independent bytecode to your system.
Applets were used for enhancing the user experience on the web, in business applications, games, and other consumer applications. The Java Security Manager sand-boxed these applets to provide assurance to end users that this downloaded untrusted code could not access anything on their local systems without their permission, nor make network connections except back to its originating host. And to print, it had to ask the end user directly. This was all revolutionary at the time.
The World Is Now Different
Because deployment models have changed and browsers stopped supporting the plugin model, applets are no longer possible on modern web browsers.
But outside of the web browser / downloaded untrusted code scenario, the java.applet API package rarely made sense for end user applications and so without that, it has long been a mostly non-functional part of the java.desktop module.
The standalone JDK has never itself provided any way to run applets, even though it provided the API.
Some other code, like the Java plugin, which was never a part of the OpenJDK project, or the bundled appletviewer tool meant for developer testing, or the JDK’s regression test framework, jtreg, also a developer only tool, provided the implementation.
The final nail was that JDK 24 permanently disabled the Java Security Manager, so the sandbox for running untrusted code was no longer possible.
So it is time to remove the Applet API from the latest tip JDK. Taking account of the long history and many uses of Applets over the years, this removal has not been done without lots of warnings, preparation, and consideration.
The preparatory work to remove java.applet has been ongoing since 2016, so it will have been a 10 year project.
It began with deprecating the Applet API in JDK 9, then deprecating-for-removal in JDK 17 in 2021.
Also, the bundled appletviewer tool was deprecated in JDK 9 and then removed in JDK 11 in 2018.
A lot of effort was spent on updating thousands of JDK jtreg-based functional tests to no longer rely on the Applet API, tweaking specifications that incidentally mention applets, etc. - a huge effort.
So, it will have taken 10 years to get to this point of removal. Please don’t say you briefly looked elsewhere and somehow missed all of these memos!
So What Now?
JDK 8 updates continue to support applets for increasingly rare legacy browser situations and also support Java Web Start (JNLP) enabled applets.
We now encourage developers to use jpackage to deploy Java applications to end-users.
This JDK-provided tool creates native platform installers, so that a Java program installs on their system like any other application.
We expect that only a very few standalone AWT/Swing applications use the Applet API and they should be able to migrate.
The class java.applet.Applet is just a subclass of java.awt.Panel, so it is easy to migrate unless they use a method specific to Applet.
This is likely very rare for desktop applications and in general these were never useful for such a case.
Some users reported that they didn’t use the Applet API for applets but used java.applet.AudioClip as a convenient audio playback API in applications.
In JDK 25, we introduced javax.sound.SoundClip as a replacement for that.
If you need further help migrating away from the Applet API, contact your support provider.
The rest of the java.desktop module (i.e. AWT, Swing, Java 2D) in the JDK is unaffected in functionality and continues to be supported and enhanced.
