Interface: NsisWebOptions
Web Installer options.
Extends
Properties
allowElevation?
readonlyoptionalallowElevation?:boolean
assisted installer only. Allow requesting for elevation. If false, user will have to restart installer with elevated permissions.
Default
true
Inherited from
allowToChangeInstallationDirectory?
readonlyoptionalallowToChangeInstallationDirectory?:boolean
assisted installer only. Whether to allow user to change installation directory.
Default
false
Inherited from
NsisOptions.allowToChangeInstallationDirectory
allowUnelevatedPerMachineUpdate?
readonlyoptionalallowUnelevatedPerMachineUpdate?:boolean
assisted installer only, with perMachine not set. Let a silent update (--updated) of a per-machine installation run without a UAC
prompt when the user already holds every access right the update uses. Off by default: the update elevates, as before.
An update removes and re-creates the installation folder, the app's HKLM registration and the all-users shortcuts, so this applies
only where an administrator granted standard users those rights: on the folder and its files, its parent folder, the
INSTALL_REGISTRY_KEY and Uninstall keys and their parent keys (HKLM\Software,
HKLM\Software\Microsoft\Windows\CurrentVersion\Uninstall), and the Start Menu folder and Public Desktop. The installer and
the uninstaller check each right without changing anything, and elevate when one is missing, when a per-user installation exists too,
and for an interactive install or uninstall.
electron-builder does not recommend granting these rights: an unelevated process could then change the UninstallString that the
elevated uninstaller, and deployment tools running as SYSTEM, later execute. The option is for machines whose administrators already
did.
An update runs the uninstaller of the installed version, so the first update to a build with this option still elevates.
Not checked: HKLM\Software\Classes (file associations and protocols), writes made by customInstall or customUnInstall, and
shortcuts or a Start Menu folder that an earlier version created under another name. Without elevation, a write there that is
denied fails without an error, so leave this option off if the update needs one.
Default
false
Inherited from
NsisOptions.allowUnelevatedPerMachineUpdate
allowUnverifiedAppPackage?
readonlyoptionalallowUnverifiedAppPackage?:boolean
Whether the web installer may install an app package that doesn't match any package built with it: a package passed via --package-file,
or (when appPackageUrl is not set) the downloaded package. By default such a package aborts the installation.
Enable only if you intentionally run one web installer with packages of other builds (e.g. a version-independent installer with --package-file).
Default
false
appPackageUrl?
readonlyoptionalappPackageUrl?:string|null
The application package download URL. Optional — by default computed using publish configuration.
URL like https://example.com/download/latest allows web installer to be version independent (installer will download latest application package).
Please note — it is full URL.
Custom X-Arch http header is set to 32 or 64.
The installer does not checksum-verify a package downloaded from an explicit appPackageUrl; a package downloaded from the default (publish-derived) URL is verified against the packages built with the installer.
artifactName?
readonlyoptionalartifactName?:string|null
The artifact file name template. Defaults to ${productName} Web Setup ${version}.${ext}.
Overrides
buildUniversalInstaller?
readonlyoptionalbuildUniversalInstaller?:true
Override for NsisOptions.buildUniversalInstaller. nsis-web requires universal installer
Default
true
Overrides
NsisOptions.buildUniversalInstaller
createDesktopShortcut?
readonlyoptionalcreateDesktopShortcut?:boolean|"always"
Whether to create desktop shortcut. Set to always if to recreate also on reinstall (even if removed by user).
Default
true
Inherited from
NsisOptions.createDesktopShortcut
createStartMenuShortcut?
readonlyoptionalcreateStartMenuShortcut?:boolean
Whether to create start menu shortcut.
Default
true
Inherited from
NsisOptions.createStartMenuShortcut
deleteAppDataOnUninstall?
readonlyoptionaldeleteAppDataOnUninstall?:boolean
one-click installer only. Whether to delete app data on uninstall.
Default
false
Inherited from
NsisOptions.deleteAppDataOnUninstall
differentialPackage?
readonlyoptionaldifferentialPackage?:boolean|"compressed"|"store-asar"
Marks the package as built with differential download support for the update server, and selects how the app package is compressed:
false— no differential download support."store-asar"— differential-aware, with the app'sresources/app.asarstored uncompressed (7-ZipCopy) inside the package. The differential updater diffs the compressed package with a content-defined blockmap, and the asar is a single compressed member — so any change to app code re-downloads the entire compressed asar (~100% of the member; its header rewrite alone diverges every block). Storing it keeps unchanged regions byte-identical between releases, making the delta proportional to what actually changed (measured on a ~32 MB asar: a one-line source change cost 0.2% instead of 100%). The stored asar's byte range is also chunked with finer content-defined blocks (4/8/16 KiB instead of the 8/16/32 KiB used for the rest of the installer), so a small change costs proportionally fewer bytes still. Trade-off: the installer and full package grow by roughly what compressing the asar saved. Without anapp.asar(e.g.asaris disabled) there is nothing to store, so it behaves liketrue. Upgrading from an electron-builder without the finer chunking changes the block boundaries once: the first differential update from an installer built before it re-downloads close to the whole asar, and updates between installers built with it are proportional again. Pair it withasar.contentAlignment(e.g.512) so that a change which grows a file does not shift every later file's offset in the asar header.- anything else (
true,"compressed", unset) — differential-aware, whole package compressed.
Default
true
Inherited from
NsisOptions.differentialPackage
displayLanguageSelector?
readonlyoptionaldisplayLanguageSelector?:boolean
Whether to display a language selection dialog. Not recommended (by default will be detected using OS language).
Default
false
Inherited from
NsisOptions.displayLanguageSelector
guid?
readonlyoptionalguid?:string|null
The GUID for the installer. Used to identify the application for upgrade and uninstall operations.
If not specified, a deterministic GUID is generated from the app ID (appId) — but this means
changing your appId will break silent upgrades of existing installs.
See
Inherited from
include?
readonlyoptionalinclude?:string|string[] |null
The path to NSIS include script to customize installer, or an array of such paths to include multiple scripts. Defaults to build/installer.nsh. See Custom NSIS script.
Each path is resolved relative to the build resources directory first and then relative to the project directory. When an array is provided, all scripts are included in the specified order.
Inherited from
installerDebugLogging?
readonlyoptionalinstallerDebugLogging?:boolean
Whether to enable NSIS logging in the installer and uninstaller (LogSet on, which writes install.log to the installation
directory). The installer logs from the install of the files on (once the previous version is uninstalled); the uninstaller logs
from its start and leaves the open install.log in place when an update moves the installation directory aside. In your custom
NSIS scripts, write to the log via ${LogText}; in customInit / preInit nothing is logged yet.
Requires a log-enabled NSIS: makensis and its stubs compiled with NSIS_CONFIG_LOG=yes. From toolsets.nsis "2.0.4" (the
default) on, each NSIS release publishes a log-enabled bundle next to the default one, and electron-builder downloads it when this
option is true (the default bundle otherwise). Its stubs make the installer and uninstaller up to about 8 KB larger, and they
write a log only once LogSet on runs, which this option adds. The older pinned bundles ("0.0.0", "1.2.1") have no
log-enabled variant, and the build fails with one of them. A custom toolsets.nsis bundle must be log-enabled itself.
Replaces the v26 customNsisBinary.debugLogging.
See
Default
false
Inherited from
NsisOptions.installerDebugLogging
installerHeader?
readonlyoptionalinstallerHeader?:string|null
assisted installer only. MUI_HEADERIMAGE, relative to the build resources or to the project directory.
Default
build/installerHeader.bmp
Inherited from
installerHeaderIcon?
readonlyoptionalinstallerHeaderIcon?:string|null
one-click installer only. The path to header icon (above the progress bar), relative to the build resources or to the project directory.
Defaults to build/installerHeaderIcon.ico or application icon.
Inherited from
NsisOptions.installerHeaderIcon
installerIcon?
readonlyoptionalinstallerIcon?:string|null
The path to installer icon, relative to the build resources or to the project directory.
Defaults to build/installerIcon.ico or application icon.
Inherited from
installerLanguages?
readonlyoptionalinstallerLanguages?:string|string[] |null
The installer languages (e.g. en_US, de_DE). Change only if you understand what do you do and for what.
Inherited from
NsisOptions.installerLanguages
installerSidebar?
readonlyoptionalinstallerSidebar?:string|null
assisted installer only. MUI_WELCOMEFINISHPAGE_BITMAP, relative to the build resources or to the project directory.
Defaults to build/installerSidebar.bmp or ${NSISDIR}\\Contrib\\Graphics\\Wizard\\nsis3-metro.bmp. Image size 164 × 314 pixels.
Inherited from
language?
readonlyoptionallanguage?:string|null
LCID Dec, defaults to 1033(English - United States).
Inherited from
license?
readonlyoptionallicense?:string|null
The path to EULA license file. Defaults to license.txt or eula.txt (or uppercase variants). In addition to txt, rtf and html supported (don't forget to use target="_blank" for links).
Multiple license files in different languages are supported — use lang postfix (e.g. _de, _ru). For example, create files license_de.txt and license_en.txt in the build resources.
If OS language is german, license_de.txt will be displayed. See map of language code to name.
Appropriate license file will be selected by user OS language.
Inherited from
menuCategory?
readonlyoptionalmenuCategory?:string|boolean
Whether to create submenu for start menu shortcut and program files directory. If true, company name will be used. Or string value.
Default
false
Inherited from
multiLanguageInstaller?
readonlyoptionalmultiLanguageInstaller?:boolean
Whether to create multi-language installer. Defaults to unicode option value.
Inherited from
NsisOptions.multiLanguageInstaller
oneClick?
readonlyoptionaloneClick?:boolean
Whether to create one-click installer or assisted.
Default
true
Inherited from
packElevateHelper?
readonlyoptionalpackElevateHelper?:boolean
Whether to pack the elevate executable (required for electron-updater if per-machine installer used or can be used in the future). Ignored if perMachine is set to true.
Default
true
Inherited from
perMachine?
readonlyoptionalperMachine?:boolean
Whether to show install mode installer page (choice per-machine or per-user) for assisted installer. Or whether installation always per all users (per-machine).
If oneClick is true (default): Whether to install per all users (per-machine).
If oneClick is false and perMachine is true: no install mode installer page, always install per-machine.
If oneClick is false and perMachine is false (default): install mode installer page.
Default
false
Inherited from
preCompressedFileExtensions?
readonlyoptionalpreCompressedFileExtensions?:string|string[] |null
The file extension of files that will be not compressed. Applicable only for extraResources and extraFiles files.
Default
[".avi", ".mov", ".m4v", ".mp4", ".m4p", ".qt", ".mkv", ".webm", ".vmdk"]
Inherited from
NsisOptions.preCompressedFileExtensions
publish?
optionalpublish?:Publish
Inherited from
removeDefaultUninstallWelcomePage?
readonlyoptionalremoveDefaultUninstallWelcomePage?:boolean
assisted installer only. remove the default uninstall welcome page.
Default
false
Inherited from
NsisOptions.removeDefaultUninstallWelcomePage
runAfterFinish?
readonlyoptionalrunAfterFinish?:boolean
Whether to run the installed application after finish. For assisted installer corresponding checkbox will be removed.
Default
true
Inherited from
script?
readonlyoptionalscript?:string|null
The path to NSIS script to customize installer. Defaults to build/installer.nsi. See Custom NSIS script.
Inherited from
selectPerMachineByDefault?
readonlyoptionalselectPerMachineByDefault?:boolean
Whether to set per-machine or per-user installation as default selection on the install mode installer page.
Default
false
Inherited from
NsisOptions.selectPerMachineByDefault
shortcutName?
readonlyoptionalshortcutName?:string|null
The name that will be used for all shortcuts. Defaults to the application name.
Inherited from
unicode?
readonlyoptionalunicode?:boolean
Whether to create Unicode installer.
Default
true
Inherited from
uninstallDisplayName?
readonlyoptionaluninstallDisplayName?:string|null
The uninstaller display name in the control panel.
Default
${productName} ${version}
Inherited from
NsisOptions.uninstallDisplayName
uninstallerIcon?
readonlyoptionaluninstallerIcon?:string|null
The path to uninstaller icon, relative to the build resources or to the project directory.
Defaults to build/uninstallerIcon.ico or application icon.
Inherited from
uninstallerSidebar?
readonlyoptionaluninstallerSidebar?:string|null
assisted installer only. MUI_UNWELCOMEFINISHPAGE_BITMAP, relative to the build resources or to the project directory.
Defaults to installerSidebar option or build/uninstallerSidebar.bmp or build/installerSidebar.bmp or ${NSISDIR}\\Contrib\\Graphics\\Wizard\\nsis3-metro.bmp
Inherited from
NsisOptions.uninstallerSidebar
uninstallUrlHelp?
readonlyoptionaluninstallUrlHelp?:string|null
The URL to the uninstaller help page in the control panel. Defaults to homepage from application package.json.
Inherited from
uninstallUrlInfoAbout?
readonlyoptionaluninstallUrlInfoAbout?:string|null
The URL to the uninstaller info about page in the control panel. Defaults to homepage from application package.json.
Inherited from
NsisOptions.uninstallUrlInfoAbout
uninstallUrlReadme?
readonlyoptionaluninstallUrlReadme?:string|null
The URL to the uninstaller readme page in the control panel. Defaults to homepage from application package.json.
Inherited from
NsisOptions.uninstallUrlReadme
uninstallUrlUpdateInfo?
readonlyoptionaluninstallUrlUpdateInfo?:string|null
The URL to the uninstaller update info page in the control panel. Defaults to homepage from application package.json.
Inherited from
NsisOptions.uninstallUrlUpdateInfo
useZip?
readonlyoptionaluseZip?:boolean
Use zip instead of 7z (LZMA) for the embedded app package. Only applies to portable targets and to installers built with differentialPackage: false; ignored (with a warning) when differentialPackage is enabled and for nsis-web, which always use 7z.
Default
false
Inherited from
warningsAsErrors?
readonlyoptionalwarningsAsErrors?:boolean
If warningsAsErrors is true (default): NSIS will treat warnings as errors. If warningsAsErrors is false: NSIS will allow warnings.
Default
true