Skip to main content

Target Selection Guide

This page helps you choose the right packaging format for each platform. The right choice depends on your distribution method, target audience, and operational requirements.

Windows Targets

TargetFormatBest ForAdmin RequiredAuto-Update
nsis.exe installerConsumer apps (most common)Optional (per-user mode)electron-updater
nsis-web.exe web installerApps with large assetsOptionalelectron-updater
portable.exe no-installUSB drives, no-install scenariosNoManual
appx.appx / .msixWindows Store, enterprise MDMManaged by StoreStore only
msi.msiEnterprise deployment (SCCM/Intune/GPO)YesNot supported via electron-updater
msi-wrapped.msi wrapping NSISEnterprise + existing NSIS installerYeselectron-updater
squirrel.windows.exe / NuGetLegacy (not recommended)NoSquirrel

When to Use Each Windows Target

NSIS (nsis) — the default and best choice for most applications.

  • Consumer software distributed via your website or GitHub releases
  • Both per-user (no admin) and per-machine install modes available
  • Script-based customization via NSIS macros (.nsh hooks) — not visual UI theming
  • Works with electron-updater for auto-updates

NSIS Web (nsis-web) — use when your app download is very large.

  • Produces a small stub installer that downloads the full payload at install time
  • Suitable for apps with many platform-specific binaries
  • Requires internet connectivity at install time

Portable (portable) — use when no installation at all is the goal.

  • Single executable, runs from any location
  • No registry entries, no Start menu entries
  • Common for developer tools, USB-stick deployments
  • Auto-updates require manual implementation

AppX (appx) — use for Windows Store distribution or enterprise MDM.

  • Required for listing in the Microsoft Store
  • Enterprise IT can deploy via Intune/MDM without the Store
  • Code signing with a trusted certificate is required for sideloading
  • See AppX Configuration

MSI (msi) — use for enterprise deployment via Group Policy or SCCM.

  • IT departments can deploy silently across managed machines
  • Supports standard MSI command-line flags (/quiet, /passive)
  • Upgrade code is critical — changing it breaks silent upgrades of existing installs
  • See MSI Configuration

MSI-Wrapped (msi-wrapped) — use when you need MSI packaging but want NSIS features.

  • Wraps your existing NSIS installer inside an MSI container
  • Enables Group Policy deployment of apps with NSIS-based setup logic
  • See MSI-Wrapped Configuration

Windows Decision Tree

Do you need Windows Store distribution?
→ Yes: AppX

Do you need enterprise GPO/SCCM/Intune deployment?
→ Yes, native MSI: MSI
→ Yes, but keep NSIS features: MSI-Wrapped

Is this a consumer app?
→ Normal installer: NSIS (default)
→ Very large download: NSIS-Web
→ No installation at all: Portable

macOS Targets

TargetFormatBest ForCode SigningNotarization
dmg.dmg disk imageStandard consumer distributionDeveloper ID ApplicationRequired (10.15+)
pkg.pkg installerSystem-level installs, launch agentsDeveloper ID InstallerRequired (10.15+)
zip.zip archiveUpdate server payload, minimal sizeDeveloper ID ApplicationRequired (10.15+)
masApp bundle (Store)Mac App StoreApple DistributionNo (Apple signs)
mas-devApp bundle (dev)Testing MAS builds locallyApple DevelopmentNo
dirDirectoryDevelopment / debuggingOptionalNo

When to Use Each macOS Target

DMG (dmg) — the standard for consumer macOS distribution.

  • Drag-and-drop install with /Applications shortcut
  • Customizable window, background, icon layout
  • electron-updater supports updates via ZIP payload
  • See DMG Configuration

PKG (pkg) — use when you need system-level installation.

  • Required for kernel extensions, launch daemons, or files outside /Applications
  • Pre/post-install scripts via the scripts directory
  • Requires a separate "Developer ID Installer" certificate
  • See PKG Configuration

ZIP — use as the update payload for electron-updater.

  • Smaller than DMG for the same content
  • Not user-facing — used internally by the auto-update mechanism
  • Commonly built alongside DMG

MAS (mas) — required for Mac App Store submission.

  • Uses App Sandbox — your app must declare all permissions via entitlements
  • Requires provisioning profiles
  • Apple handles signing during the Store submission process
  • See MAS Configuration

macOS Decision Tree

Is the app going to the Mac App Store?
→ Yes: MAS
→ Testing MAS builds: mas-dev

Does the app install system components (daemons, kernel extensions)?
→ Yes: PKG

Standard consumer distribution?
→ Yes: DMG (+ ZIP for auto-updates)

Linux Targets

TargetFormatBest ForSandboxedDistro Support
AppImage.AppImageUniversal, no installNoUniversal
deb.debDebian, Ubuntu, MintNoDebian-based
rpm.rpmFedora, RHEL, openSUSENoRPM-based
snapSnap packageUbuntu-primary, Store distributionYesAny (snapd)
flatpakFlatpak bundleCross-distro sandboxedYesAny (flatpak)
pacman.pkg.tar.zstArch Linux, ManjaroNoArch-based
apk.apkAlpine Linux, DockerNoAlpine
freebsd.pkgFreeBSDNoFreeBSD
p5pIPS packageSolaris / illumosNoSolaris-based
zip, tar.gzArchiveCDN / custom deploymentNoUniversal

When to Use Each Linux Target

AppImage — built by default alongside Snap; best first choice for broad compatibility.

  • Single file, no installation, no root required
  • Runs on virtually any x86_64 Linux distribution
  • AppImageLauncher handles desktop integration
  • electron-updater supports delta updates via embedded blockmap (no separate file needed)
  • See AppImage Configuration

DEB — use for Debian-based distribution (Ubuntu, Mint, etc.).

  • Installable via apt from a repository or directly
  • Best when targeting Ubuntu users who expect .deb packages
  • See Linux Configuration → DEB

RPM — use for Red Hat-based distribution (Fedora, RHEL, CentOS, openSUSE).

Snap — use for Ubuntu-primary distribution via the Snap Store.

  • Automatic updates via Snap Store
  • Sandboxed with strict confinement
  • Required for Snap Store listing
  • See Snap Configuration

Flatpak — use for cross-distro sandboxed distribution.

  • Works on any distro with flatpak installed
  • electron-builder produces single-file bundles (not Flathub repository packages)
  • See Flatpak Configuration

Pacman — use for Arch Linux and Arch-based distributions.

APK — use for Alpine Linux or Docker container base images.

Linux Decision Tree

Universal distribution, no install required?
→ AppImage (default)

Ubuntu Store / auto-update via Snap?
→ Snap

Cross-distro sandbox?
→ Flatpak

Debian/Ubuntu apt repository?
→ DEB

Fedora/RHEL/openSUSE dnf repository?
→ RPM

Arch Linux?
→ Pacman (beta)

Alpine / Docker?
→ APK

Combining Multiple Targets

You can build multiple targets in a single run:

# electron-builder.yml
win:
target:
- nsis
- portable

mac:
target:
- dmg
- zip

linux:
target:
- AppImage
- deb
# CLI: build all configured targets
electron-builder --mac --win --linux

# Build specific targets
electron-builder --win nsis --win msi

# Build for specific architectures
electron-builder --mac --x64 --arm64