The boilerplate uses electron-updater for auto-updates. Out of the box it's wired for GitHub Releases (free, no infra) and any S3-compatible bucket (R2, B2, MinIO — flip one env var).
How it works
- The app boots and silently asks the update server: "is there a newer version?"
- If yes, it downloads the delta in the background.
- On next launch (or after a prompt), the new version installs.
The user does nothing. You publish once; every running install upgrades.
Path A: GitHub Releases (free, recommended to start)
1. Set your repo
Make sure package.json → repository.url and electron-builder.yml → publish.owner/repo point at the repo you set with npm run rebrand.
2. Create a GitHub Personal Access Token
Generate one with repo scope at github.com/settings/tokens. Add it to your shell env (or a local .env.publish, gitignored):
export GH_TOKEN=ghp_xxxxxxxxxxxxxxxx3. Bump the version and publish
npm version patch # or minor / major — updates package.json
npm run publish # builds, signs, uploads to GitHub ReleasesThat's it. Every user running an older version will pick up the new release within hours.
Test the update flow before shipping
Install your current release on a test machine. Then npm version patch && npm run publish. Re-launch the test app — you'll see the updater download the new version.
Path B: S3-compatible host (Cloudflare R2, Backblaze B2, MinIO)
When you don't want every release public on GitHub:
- Make a bucket on R2 / B2 / MinIO with public read on the release prefix.
- In
electron-builder.yml, changepublish.providerfromgithubtogenericand seturlto your bucket URL. - Set
AWS_ACCESS_KEY_IDandAWS_SECRET_ACCESS_KEYin your env. npm run publish— same command, different destination.
Auto-update requires code-signing on macOS
Unsigned macOS apps can't auto-update (Gatekeeper blocks the swap). See Code-signing before you ship to Mac users. Windows works unsigned but users see SmartScreen warnings.
Ask your AI assistant
"My GitHub Releases auto-update is failing with 'ENOENT no such file or directory' when the updater tries to apply the diff. Diagnose: read electron-builder.yml, package.json, and the relevant electron-updater source, then suggest the most likely causes."
What's next
- Sign before you ship → Code-signing for Windows + macOS