Back to thoughts
Jan 20265 min read

Building a Cross-Platform Desktop App with Electron

Shipping one codebase to Windows, macOS and Linux with Electron — the main/renderer split, packaging, and keeping a web stack feeling native.

Electron let me ship a desktop app to Windows, macOS and Linux from a single web-stack codebase — reusing the React and Node skills I already had instead of learning three native toolkits.

Main vs renderer

The architecture splits cleanly: a Node main process owns the window, the filesystem and OS integration, while the renderer is the UI. Keeping that boundary strict — and talking across it through a narrow, validated bridge — is what keeps an Electron app secure and maintainable.

Native enough

The work that makes it not feel like "a website in a window" is the details: real menus, keyboard shortcuts, file dialogs, and packaging plus auto-update for each platform. That's where most of the effort actually goes.

One codebase, three platforms, and a stack I already knew — for the right app, that trade is hard to beat.