diff --git a/src/jdk.jpackage/windows/classes/jdk/jpackage/internal/WinMsiBundler.java b/src/jdk.jpackage/windows/classes/jdk/jpackage/internal/WinMsiBundler.java
index 8acbd60b11e..5aecb5b82cc 100644
--- a/src/jdk.jpackage/windows/classes/jdk/jpackage/internal/WinMsiBundler.java
+++ b/src/jdk.jpackage/windows/classes/jdk/jpackage/internal/WinMsiBundler.java
@@ -106,8 +106,9 @@
* value generated by jpackage every time {@link #execute} method is called if
* --win-upgrade-uuid command line option is not specified. Otherwise this
* variable is set to the value of --win-upgrade-uuid command line option
- *
JpAllowDowngrades. Set to "yes" if --win-upgrade-uuid command line option
- * was specified. Undefined otherwise
+ * JpAllowUpgrades. Set to "yes", but all that matters is it is defined.
+ * JpAllowDowngrades. Defined for application installers, and undefined for
+ * Java runtime installers.
* JpConfigDir. Absolute path to the directory with generated WiX source
* files.
* JpIsSystemWide. Set to "yes" if --win-per-user-install command line
@@ -450,7 +451,9 @@ private Map prepareMainProjectFile(
upgradeCode));
data.put("JpAllowUpgrades", "yes");
- data.put("JpAllowDowngrades", "yes");
+ if (!StandardBundlerParam.isRuntimeInstaller(params)) {
+ data.put("JpAllowDowngrades", "yes");
+ }
data.put("JpAppName", APP_NAME.fetchFrom(params));
data.put("JpAppDescription", DESCRIPTION.fetchFrom(params));
diff --git a/src/jdk.jpackage/windows/classes/jdk/jpackage/internal/resources/main.wxs b/src/jdk.jpackage/windows/classes/jdk/jpackage/internal/resources/main.wxs
index 07cbe0d333f..c5e1e6d8b58 100644
--- a/src/jdk.jpackage/windows/classes/jdk/jpackage/internal/resources/main.wxs
+++ b/src/jdk.jpackage/windows/classes/jdk/jpackage/internal/resources/main.wxs
@@ -12,6 +12,8 @@
+
+
@@ -23,8 +25,6 @@
-
-
to enable or
+to disable (the value doesn't mater).
- JpAllowUpgrades
Should be defined to enable upgrades and undefined to disable upgrades.
-Default value is `yes`.
+By default it is defined, use to disable.
-->