
Which Versions of Java Are Free
Executive Summary:
Oracleโs changes to Java licensing have left many enterprises asking which versions of Java are free for use in business environments. The Oracleย Java licensing overview shows how free and paid editions evolved.
In short, while the Java platform itself remains free and open-source at its core, not all Java versions and distributions are free for commercial use.
This advisory breaks down which versions of Java are free, highlights real-world licensing pitfalls, and provides guidance for IT, procurement, and finance teams at global enterprises on navigating Java licensing to minimize unnecessary costs and compliance risks.
The Changing Landscape of Java Licensing
Insight: Java was historically free for general use, but Oracleโs licensing changes in recent years have introduced new costs for enterprises.
In 2019, Oracle began requiring a subscription for commercial use of Oracle Java updates โ a shift often dubbed the introduction of a โJava tax.โ
This meant that, after certain versions (around Java 8 update 202 and all releases from Java 11 onward),ย Java is no longer free for commercial production useย unless specific conditions are met or alternative distributions are used.
Example: Consider a financial firm that built dozens of internal applications on Java 8. After 2019, they discovered that continuing to update Oracleโs Java 8 in production required a paid Java SE Subscription. This was a surprise, as the team had always assumed Java was freely usable. Another example is a retailer that upgraded some systems to Java 11 (a Long-Term Support version) without realizing Oracleโs Java 11 required a subscription for production use โ a costly oversight.
Takeaway: The era of โfree-for-allโ Java from Oracle is over for businesses. Enterprises must stay informed about Java licensing updates. When Oracle releases a new Java version, donโt assume itโs free for commercial use โ always verify the license and terms. A proactive review of Java versions in use can prevent compliance problems and budget surprises. An introductory explanation of licensing models appears in Oracleย Java licensing explained.
Which Versions of Java Are Free (and Which Are Not)
Insight: To answer which versions of Java are free, we need to distinguish between free open-source Java and Oracleโs licensed Java. All Java versions are available in some free form via the OpenJDK project or third-party builds.
The question is more about Oracleโs official JDK versions and updates, which have varying license terms:
- Java 8 (LTS): Oracleโs JDK 8 was free for commercial use up to Java 8 update 202. Updates released from April 2019 onward (e.g., 8u211 and above) require a paid license for commercial use. Oracle Java 8 is still free for personal use and development/testing under Oracleโs OTN License, but not free for most business production purposes. However, OpenJDK 8 (and other vendorsโ Java 8 builds) remain free and can be used as an alternative for updates.
- Java 11 (LTS): Oracle JDK 11 is not free for production use. Oracle shifted to an OTN license for Java 11, meaning only development and personal/test use are free. Any enterprise using Oracleโs Java 11 in production needs a subscription. Free alternatives exist: Java 11 can be used for free if you deploy an OpenJDK 11 distribution (from Oracleโs open source build or another provider) โ those are free and open-source. However, youโd be responsible for applying updates yourself or obtaining support elsewhere.
- Java 17 (LTS): Oracle JDK 17 was initially offered under a special No-Fee Terms and Conditions (NFTC) license. This made Java 17 free for all users, including production, but with a time limit. Oracle is committed to providing Java 17 updates free under NFTC until one year after the next LTS release. In practice, Java 17 updates were free until September 2024. After that, Oracle requires a paid subscription for any further Java 17 updates. In other words, Oracle Java 17 was โfreeโ for a window of time. If you continue running Oracle JDK 17 without upgrading beyond that window, you risk running outdated software or needing to pay for support. (Again, using an OpenJDK 17 build from a third party remains free outside of Oracleโs ecosystem.)
- Java 21 (LTS): Oracle JDK 21, released in late 2023, is also provided under the NFTC license for now. It is free for all uses during its active support period. Oracle has stated Java 21 will remain free under NFTC until at least September 2026 (one year after the expected next LTS, Java 25, in 2025). After that, Oracle will likely switch Java 21 to a paid support model (similar to what happened with 17). Today, Java 21 is free to download and use in production without cost โ but enterprises must have an upgrade plan in place before the free period lapses.
- Java 9, 10, 12, 13, 14, 15, 16, etc.: These interim versions were short-term releases. Oracleโs distributions of these versions came out after the licensing shift, so technically, they required a subscription for commercial use at the time. However, most companies avoided deploying these non-LTS versions in production. If they did, they likely used OpenJDK builds, which are free but had very short support windows (these versions reach end-of-life within six months). In essence, all non-LTS versions are freely available through open-source channels, but Oracle doesnโt support them long-term without a contract. Many enterprises stick to LTS versions for stability.
- Java 7 and earlier: Older versions, such as Java 7, 6, and 5, were released under the old Sun/Oracle Binary Code License, which permitted free commercial use of the runtime. That means you can technically use those old Oracle JDK binaries without paying Oracle. However, they are end-of-life and no longer receive updates, so running them poses security risks. If an enterprise needs to run Java 7 or 6 in production, it typically either does so without support (a risky approach) or pays a third-party support vendor for patches. Oracle offers paid extended support for Java 7 (and previously offered it for Java 6) via support contracts, but not free updates. In short, those versions are โfree to useโ in terms of license fee, but not getting any fixes.
Example: A global manufacturing company conducted an internal audit and discovered that it had applications running on both Java 11 and Java 8. The Java 8 installations were at update 231 (which is beyond the free public 8u202), meaning those instances technically required an Oracle license. Meanwhile, their Java 11 instances were the Oracle JDK 11, which also required a subscription that they hadnโt budgeted for. They migrated the Java 11 apps to an open-source build (avoiding Oracle fees) and replaced Java 8 with Amazonโs free Corretto 8 distribution to stay on secure, updated versions without license costs.
Takeaway: Which versions of Java are free? Essentially, any Java version can be free if you choose the right distribution. Oracleโs official JDK builds are only free for certain versions or for limited use cases. To avoid costs, enterprises should either stick to the versions Oracle currently offers under no-fee terms (keeping in mind those terms expire), or use open-source Java distributions that are free for commercial use. Always confirm the update level and license of any Oracle JDK in use โ if itโs beyond the free allowance, you either need to pay or switch to an alternative. Requirements for older releases are clarified in Oracleย Java licensing for legacy versions โ Javaย 6/7/8/11.
Free Java Alternatives to Oracleโs JDK
Insight: Oracle is not the only provider of Java. The Java platform is open-source (through OpenJDK), and multipleย free Java distributionsย are enterprise-ready.
These alternatives are built on the same OpenJDK source code and are functionally equivalent to Oracle JDK, often certified by the Java Technology Compatibility Kit (TCK). Choosing a free alternative can liberate your enterprise from Oracleโs licensing fees, provided you manage updates and support effectively.
Key free Java options include:
- OpenJDK Builds: Oracle itself provides OpenJDK builds for each Java release under an open-source license (GPL with Classpath Exception). For example, you can download OpenJDK 17 or 21 for free. The catch is that Oracleโs OpenJDK releases are only updated until the next version is released (for LTS, Oracle provided OpenJDK 17 updates for six months after the release). After that, Oracleโs OpenJDK binaries stop updating. However, the open-source nature means that others can continue to support it.
- Eclipse Temurin (Adoptium): Temurin is a popular free OpenJDK distribution managed by the Eclipse Foundation (formerly known as AdoptOpenJDK). It provides free binaries for Java 8, 11, 17, 21, and more, with an emphasis on reliability. Many enterprises use Temurin as a drop-in replacement for Oracle JDK. Itโs TCK-tested and updated with security patches (the community and vendors collaborate to provide updates for LTS versions for several years).
- Amazon Corretto: Amazonโs Corretto is a no-cost, production-ready distribution of OpenJDK. Amazon commits to long-term support for Corretto (they have provided free updates for Java 8 and 11 for years, and offer newer LTS like 17). Corretto is used internally at Amazon and offered to the public, and it includes security updates tuned for AWS but usable anywhere, free of charge.
- Azul Zulu and Others: Azul Systems provides Zulu Community Edition, another free OpenJDK build for various Java versions (including extended support for older versions). They also offer paid support if needed, but the community edition is free to use. Other vendors, such as Red Hat (for its subscribers or via the community for free), IBM (OpenJ9 JVM variant), and even Microsoft (Microsoft’s Build of OpenJDK), provide free Java distributions. Each of these is based on the same core OpenJDK, just packaged and supported by different organizations.
Example: A large international bank decided to avoid Oracleโs Java fees by standardizing on Eclipse Temurin for all its Java needs. They replaced Oracle JDK 8 and 11 on hundreds of servers with Temurin builds. The transition was smooth because the code ran the same โ the only difference was the source of the JDK. In another case, a tech company chose Amazon Corretto 11 for their microservices in AWS, benefiting from Amazonโs regular patches at no cost. These companies avoided seven-figure subscription costs by using free JDK distributions, while still receiving timely security updates.
Takeaway: Global enterprises have strong alternatives to Oracle JDK that are free. If youโre asking which versions of Java are free, remember that itโs not just about the version number, but also the distribution. By adopting a well-supported OpenJDK distribution (like Temurin, Corretto, or others), you can run the latest Java versions for free in production. Just ensure you have a plan for applying updates (either in-house or via vendor support). Free doesnโt mean โno effortโ โ you become responsible for staying current on patches โ but it can dramatically reduce direct licensing costs and eliminate Oracleโs Java fees.
โFreeโ Java Isnโt Always Free Forever
Insight: Even when Oracle labels a Java version โfree,โ there may be strings attached. The Oracle No-Fee Terms and Conditions (NFTC) for Java 17 and 21 are a prime example, as they permit the temporary free use of those Java versions in production. After a set period, new updates require a paid license. In effect, Oracleโs free Java offers can be viewed as a grace period or a strategy to encourage upgrades, rather than an indefinite free ride. Enterprises need to understand these limitations to avoid inadvertently running unlicensed software when the terms change. To see how free versions relate to headcount licensing, read Understanding Oracleโs employeeโbased Java licensing model.
Example: A global retailer eagerly adopted Oracle JDK 17 in 2022 because it was advertised as free for production use. They rolled it out across their systems. However, by late 2024, Oracleโs free updates for JDK 17 ceased (as Java 21 had been out for a year). The retailer now faced a dilemma: either upgrade every system to Java 21 (which was non-trivial with their application compatibility testing cycle) or purchase Oracle Java subscriptions to continue receiving JDK 17 security updates. This situation created urgent project work and budget pressure that could have been mitigated with better planning. Another scenario is a company using Oracle JDK 8 that enabled auto-updates: after public free updates ended, the JRE auto-update feature started suggesting newer (paid) update releases. If installed, those newer builds technically werenโt free for commercial use, creating a potential license compliance issue.
Takeaway: โFreeโ doesnโt always mean free forever. Oracleโs strategy with Java LTS releases now requires enterprises to keep up with a rapid upgrade cadence to remain on free-to-use versions. If you accept Oracleโs free usage terms (like NFTC), plan your upgrades accordingly. Before adopting a โfreeโ Oracle JDK in production, read the fine print on how long that free period lasts. In many cases, an OpenJDK-based solution might offer a more predictable, indefinite free usage (with community-driven updates), whereas Oracleโs free license has an expiration date. Always have a roadmap for Java version upgrades or a contingency plan in place for when โfreeโ periods end.
Cost and Compliance Risks for Enterprises
Insight: Using a non-free Java version without proper licensing can lead to significant compliance risks and costs. Oracle now treats Java like any other licensable software, and it has become more proactive in auditing customers for Java usage. The cost exposure can be high โ especially after Oracleโs switch to a per-employee licensing model in 2023. Under the Java SE Universal Subscription, Oracle charges based on your total number of employees, not the number of Java installations. This means that even limited Java usage can translate into a substantial subscription bill if youโre out of compliance, as the metric may count every employee in your organization. Pricing calculations can be understood via Java price list โ how does it work to calculate the costs.
Example: Imagine a multinational company running Oracle JDK 11 on a few hundred servers without a license. During an audit, Oracle may require the company to purchase a Java SE Universal Subscription for all employees. For a firm of 10,000 employees, that could amount to millions of dollars per year (with Oracleโs current pricing at around $15 per employee per month, before volume discounts). In a real-world case, one of our clients underwent a Java audit and discovered that a widespread deployment of Oracle Java on developer workstations โ something that had been historically free โ now obligated them to a costly subscription or a rapid replacement with an alternative. The audit identified โunlicensedโ Java installations as a compliance gap, and the initial fine/proposal from Oracle was substantial, leading to urgent negotiations.
Takeaway: Non-compliance with Java licensing can result in significant financial penaltiesย and operational disruptions. Enterprises should treat Java as a licensable asset in their compliance and Software Asset Management (SAM) processes. Key cost drivers and audit triggers include: having Oracle JDK on a large number of machines, using versions past their free-update cutoff, or neglecting to track where Java is installed (for instance, embedded in third-party applications). The safest approach is to either proactively license what you use or eliminate the need for a license by using only free distributions. In all cases, maintain documentation of your Java sources (Oracle vs others) to defend your position in an audit. Being prepared and proactive will turn Java licensing from a risk into a manageable aspect of your IT strategy.
Cost Drivers & Audit Triggers (Table)
Scenario or Trigger | Why It Matters (Cost or Risk) |
---|---|
Widespread Oracle JDK Installations | Each instance could require a license. If Oracleโs Java is on hundreds of servers or PCs, it can trigger a requirement to license every employee under the new model โ a huge cost multiplier. |
Using Oracle Java past Free Updates | Running Java versions beyond their last free update (e.g., Oracle JDK 8u211+, 11.0.3+, 17.0.13+) means youโre using software that Oracle deems commercial. In an audit, these count as unlicensed deployments, incurring back-dated subscription fees or penalties. |
Auto-Updates or Uncontrolled Installs | Developers or admins who download Oracle JDK or allow auto-update might unknowingly deploy a paid version. These โrogueโ installations often slip under the radar until an audit finds them, by which time the exposure is enterprise-wide. |
Bundled Java in Third-Party Apps | Some enterprise apps come packaged with Java. If the vendorโs license doesnโt cover it (not a โSchedule Aโ approved use under Oracleโs terms), your use of that embedded Oracle JRE could still require a license. This is a hidden compliance trap many organizations overlook. |
Legacy Java for Internal Apps | Old Java versions (Java 6, 7, 8) often remain for legacy systems. They no longer receive free security updates, so organizations either risk security breaches or pay for extended support. Keeping these in production without support can lead to incidents or forced upgrades under pressure. |
Recommendations
Develop a strategic approach to Java licensing and usage. These expert tips help global IT and procurement leaders avoid pitfalls and optimize costs:
- Inventory All Java Installations: Maintain an up-to-date inventory of which Java versions and distributions are running on all servers, VMs, containers, and endpoints. This is the foundation for any licensing or migration plan.
- Standardize on a Free Java Distribution: Choose one or two approved OpenJDK-based distributions (e.g., Eclipse Temurin, Amazon Corretto) for all new deployments. By standardizing, you avoid accidental use of Oracleโs licensed JDK and simplify support.
- Establish a Java Usage Policy: Treat Java as you would any other software asset. Create internal policies that prohibit downloading the Oracle JDK without prior approval. Implement controls so that only approved (free) JDK packages are used in development and production.
- Monitor Oracleโs Licensing Updates: Oracleโs Java licensing terms and models can change (as seen with the NFTC license and the 2023 per-employee model). Assign someone (or a team) to monitor announcements and assess how changes affect your compliance or costs. Adjust your strategy before critical deadlines are reached.
- Plan for LTS Upgrades: If you rely on free Oracle LTS versions under NFTC (like Java 21 now), plan your upgrade cycles proactively. Aim to move to the next LTS within a year of its release. This avoids falling into a paid license if you miss Oracleโs free window.
- Consider Third-Party Support: For mission-critical systems that need an older Java (or simply peace of mind), consider third-party support contracts. Companies like Azul, IBM/Red Hat, or others offer support for OpenJDK LTS releases. This can be more cost-effective and flexible than Oracleโs subscription, while maintaining your legal compliance.
- Educate Teams and Stakeholders: Ensure developers, system administrators, and procurement officers understand that not all Java is โfree.โ Regular training or briefings can prevent well-meaning staff from inadvertently downloading Oracle JDK or otherwise breaching policy.
- Engage Vendor Management in Java Decisions: If you must use Oracleโs Java (for example, certain Oracle products require it), involve your vendor management or procurement team. They can help negotiate terms or at least anticipate costs. Sometimes bundling Java usage into a broader Oracle agreement or shifting to alternatives can be part of larger vendor strategy discussions.
- Audit Your Environment Before Oracle Does: Do an internal Java license compliance audit. Use software asset management tools to detect Oracle JDK installations. This lets you remediate any issues (e.g., uninstall or replace Oracle versions) on your terms, rather than scrambling during a formal Oracle audit.
Checklist: 5 Actions to Take
Follow these key steps to ensure your enterprise is only using free Java versions or is properly licensed:
- Identify Java in Use: Scan all systems (servers, VMs, desktops, CI/CD pipelines) to locate where Java is installed. Document the version number and the distribution (Oracle, OpenJDK, vendor name).
- Verify License Requirements: For each Java installation, determine if itโs under a free-use scenario or not. Check against Oracleโs guidelines: e.g., Oracle JDK 8 update 202 or earlier is acceptable, but anything later is not free for production use. Mark any installations of Oracle JDK and beyond that are eligible for free updates, or Oracle JDK 11+ in production, as compliance risks.
- Replace or License: For any non-compliant Java usage, decide on a path:
- Replace Oracle JDK with a free alternative (of the same version, if possible, such as swapping Oracle JDK 11 with Temurin 11) and test your applications.
- Or, if replacement is not feasible in the short term, budget for an Oracle Java subscription or a third-party support contract to legitimize that usage. (Revisit this decision regularly; paying Oracle might be a temporary solution while you plan migration.)
- Implement Controls: Prevent accidental Oracle JDK installations. For example, consider restricting internal firewall access to Oracleโs Java download pages or establishing an internal repository of approved Java binaries. Ensure new projects use the company-standard JDK. Update documentation and images (e.g., Docker base images) to use the free JDK distribution.
- Monitor and Update: Continuously monitor Java versions in your environment. Set reminders for Oracleโs LTS free period deadlines (e.g., Java 21โs free updates end in 2026). Well before then, start testing and migrating to the next Java version or alternative support. Keep an eye on security updates for whatever JDK you use and apply them promptly.
By following this checklist, youโll maintain control over Java usage, prevent compliance issues, and keep your Java environment secure without overspending.
FAQ
Q: Is Java still free for commercial use?
A: Yes and no. The Java source and OpenJDK are free (under an open-source license), so you can run Java without fees using open-source distributions. However, Oracleโs official Java (Oracle JDK) is no longer universally free for commercial use. Oracle now requires a paid subscription for most business deployments, except in specific cases like using their latest LTS release within its no-fee period. In practice, Java is free for enterprises only if you choose non-Oracle distributions or carefully adhere to Oracleโs limited free-use terms.
Q: Can we use Java 8 and Java 11 in production without paying Oracle?
A: You can use Java 8 and 11 in production without paying if you do it the right way. For Java 8, you must use a build thatโs no newer than 8u202 (the last public free update) or use a free OpenJDK 8 distribution from another provider. Using Oracleโs later Java 8 updates (8u211 and above) in production requires a subscription. For Java 11, Oracleโs JDK 11 always requires a subscription for production use. The workaround is to use a free Java 11 distribution, such as Eclipse Temurin or Amazon Corretto. These are free and will run your Java 11 applications just as well, without incurring Oracle fees. Always ensure youโre using community or vendor builds that are meant to be free for commercial use.
Q: Whatโs the difference between Oracle JDK and OpenJDK?
A: Functionally, Oracle JDK and OpenJDK are almost identical in code since Java 11 and onwards. The difference is in the license and support. OpenJDK is the open-source reference implementation of Java, available for free under GPL license terms. Oracle JDK is Oracleโs build of that code, which Oracle licenses under proprietary terms for commercial support. In earlier days, the Oracle JDK had a few extra components (such as Java Web Start or improved performance in some cases), but today they are extremely similar. The key distinction: if you download Java from Oracleโs website under the Oracle license, you need to be mindful of usage terms (most enterprise uses require a subscription), whereas if you download an OpenJDK-based binary from elsewhere, itโs free to use. However, Oracleโs JDK updates come with Oracleโs official support and long-term updates (if you pay). In contrast, pure OpenJDK updates for an LTS may stop sooner unless picked up by another provider.
Q: Oracle now charges per employee for Java โ how does that work?
A: Oracleโs new Java SE Universal Subscription (introduced in 2023) uses an employee-based metric. That means the cost is calculated on the total number of employees in your organization, not the number of Java installations. For example, if you have 5,000 employees, and even if only 100 of them use Java, Oracleโs pricing would still count all 5,000. The pricing per employee per month decreases with larger employee counts; however, it can still result in a substantial bill. This model replaced the old per-processor or per-user licensing models. The intention is to simplify licensing, but many companies find it can drastically raise costs. Itโs essential to carefully evaluate this model. In some cases, it may be more cost-effective to reduce Oracle Java usage (e.g., switching to free alternatives) than to pay for an enterprise-wide Java subscription that covers all employees.
Q: How can our enterprise avoid Java licensing compliance issues?
A: To avoid compliance issues, treat Java like any other software you manage licenses for. Start by standardizing on a free Java distribution so you minimize the use of Oracleโs licensed JDK. Keep a detailed inventory of where Oracle JDK is used, and eliminate or replace those instances if possible. If you must use Oracle JDK for certain applications, consider purchasing a subscription for those specific needs or negotiating terms with Oracle โ but try to confine that usage. Regularly review Oracleโs Java licensing updates and have a migration plan for new Java versions, so youโre not caught running old versions that suddenly require a paid license. Additionally, include Java in your internal audits: check systems for any unauthorized installations of the Oracle JDK. By being proactive โ using open-source JDKs, controlling downloads, and staying informed โ you can largely avoid compliance problems and the unpleasant surprises of an Oracle audit.
Read about our Java Advisory Services.