All integration tutorials
Electron / Node.jsCreate → implement → sell

How to license and sell an Electron app

Keep license validation in Electron's main process, expose only a narrow IPC result to the renderer, and publish the app in a Store that handles payment and key delivery.

0% PermitCore commission Your payment account Automatic license delivery
TypeScript / Electron
npm
npm install @permitcore/permitcore@2.1.1
import { app } from 'electron';
import { PermitCoreClient } from '@permitcore/permitcore';

const client = new PermitCoreClient('https://api.permitcore.dev');
const result = await client.validate(
  licenseKey,
  app.getVersion(),
  productId
);

if (!result.isValid) app.quit();
One connected workflow

From product record to paid customer

Use PermitCore for the licensing layer and Store checkout. Verified paid evidence triggers the configured license issuance and queues the delivery email; test actual delivery before launch.

  1. 01
    Create

    Create the product and license policy

    In Products, create the software your key unlocks. Choose its activation limit, validity, offline grace period, version range, and feature flags.

    • Create the Electron product
    • Set activations per customer
    • Choose offline grace for desktop use
    • Copy the product ID
  2. 02
    Implement

    Install the Electron / Node.js SDK and scope the key

    Put license activation in the first-run flow and validation at startup. Pass your product ID so a valid key for another product cannot unlock this one.

    These are application fragments: supply your own key/product variables and UI or host flow. A validation call does not register a device or reserve a floating session. Check failure before protected work. Offline use needs explicitly configured trusted public keys; follow the SDK 2.1.1 offline setup. For C++, use the vcpkg registry and pinned baseline in its installation reference, rather than assuming a built-in public port.

    npm install @permitcore/permitcore@2.1.1
    • Validate in the main process
    • Return only status through a narrow IPC handler
    • Activate once and validate on later starts
    • Scope every request to the product ID
    Read the complete Electron / Node.js SDK reference
  3. 03
    Verify

    Test the real validation path

    The shown fragment performs online validation. For SDK 2.1.1 offline grace, first configure trusted public keys, a private cache directory and a stable device ID as described below. Test valid, revoked, expired and wrong-product states, then disconnected behavior after a valid signed proof has been cached.

  4. 04
    Sell

    Publish the product in your Store

    Connect your chosen Stripe, Paddle or Lemon Squeezy account, add the product to your branded PermitCore Store, and publish. Account credentials, matching catalog prices and signed webhook configuration are required. PermitCore processes the verified payment and handles Store license fulfillment.

    • Publish the app and release notes
    • Add it to your branded Store
    • Connect your chosen Store payment provider
    • Test payment-to-license delivery
    Follow the Store setup guide
    PermitCore branded Store showing software products ready to buy
    Verified payment triggers license issuance and the delivery email queue.
Before you ship

Electron / Node.js production checklist

The sample is intentionally small. Add these safeguards before making licensing part of a paid release.

Before distribution, follow the Electron license hardening guide for fuses, ASAR integrity and signed offline proof.

  • Never put privileged credentials or validation decisions in renderer code.
  • Keep contextIsolation enabled and expose a minimal preload API.
  • Test the packaged build; development and packaged storage paths differ.
  • Rate-limit repeated activation attempts in the UI and explain lockout states.
The complete commercial path

Stop at a working sale, not a working API call.

Create the license policy, ship the Electron / Node.js integration, and give buyers a Store where they can purchase it.