Needs: JDK 27 or later · Not yet tested on a real server

Enable X25519MLKEM768 in Java

Java's built-in TLS gained hybrid post-quantum key exchange in JDK 27, released on 15 September 2026 (JEP 527). It's on by default: X25519MLKEM768 is first in the default list, so a Java TLS server or client on JDK 27 uses it with any peer that supports it, with no code changes.

JDK 27 also supports SecP256r1MLKEM768 and SecP384r1MLKEM1024, the second of which is the one CNSA 2.0 buyers ask about. You can add either to the list yourself.

If your Java service sits behind a load balancer or CDN that handles TLS, configure that instead.

Before you start

Option 1: keep the defaults

  1. Look for a group list your service sets: search your start-up flags and code for jdk.tls.namedGroups and setNamedGroups.
  2. If nothing sets it, upgrade to JDK 27 or later and restart the service.
  3. If something does set it, remove it or add X25519MLKEM768 to the front of it (option 2).

Option 2: list the groups yourself

  1. Put X25519MLKEM768 first in the system property:
-Djdk.tls.namedGroups=X25519MLKEM768,x25519,secp256r1

In code, the same list goes in SSLParameters.setNamedGroups.

  1. Restart the service, then scan your domain below.

Check the change

Scan your domain to see whether every host now uses post-quantum key exchange.

Related check: Does my server support X25519MLKEM768?