# Start from a template





The fastest way to a production-shaped app is to copy an official starter project—a boilerplate you clone and change—and learn where each piece lives. Every template embeds a `pear-runtime`-family module for peer-to-peer over-the-air updates—pick the one that matches what you're shipping.

<Callout type="info">
  **New to the CLI?** Run **`pear --menu`** (Pear 3.2.0+) to browse every command from a filterable list and fill in its flags as a form, instead of memorizing them. See [Browse commands with the interactive menu](/pear/how-to/browse-commands-with-the-interactive-menu).
</Callout>

<Cards>
  <Card href="/p2p/getting-started/from-a-template/start-from-hello-pear-electron" title="hello-pear-electron (desktop)" description="An Electron GUI app: renderer ↔ main ↔ Bare worker behind a preload bridge. The shape Keet and PearPass ship." />

  <Card href="/p2p/getting-started/from-a-template/start-from-hello-pear-bare" title="hello-pear-bare (long-running terminal)" description="A standalone Bare executable for long-running programs: services, REPLs, and TUIs with no GUI and no peer dependencies." />

  <Card href="/p2p/getting-started/from-a-template/start-from-hello-pear-daemon" title="hello-pear-daemon (short-lived CLI)" description="A standalone Bare executable for commands that run and exit: a detached bare-daemon updater checks for updates in the background after the command returns." />

  <Card href="/p2p/getting-started/from-a-template/start-from-hello-pear-qvac-tui" title="hello-pear-qvac-tui (on-device AI terminal)" description="A terminal app that runs a language model on the user's own machine: two Bare workers, one for updates and one for QVAC inference, behind a bare-tui interface." />

  <Card href="/p2p/getting-started/from-a-template/start-from-hello-pear-react-native" title="hello-pear-react-native (mobile)" description="An Expo/React Native app: a Bare worklet embedded via pear-mobile, with the same over-the-air updates. The mobile counterpart to hello-pear-electron." />
</Cards>

## Which one? [#which-one]

* **Building a desktop GUI?** Start from [hello-pear-electron](/p2p/getting-started/from-a-template/start-from-hello-pear-electron)—it ships a renderer and the preload bridge that connects your UI to peer-to-peer logic in a Bare worker.
* **Building a long-running headless program—a service, REPL, or TUI?** Start from [hello-pear-bare](/p2p/getting-started/from-a-template/start-from-hello-pear-bare)—it compiles to a single standalone binary per OS and architecture and keeps your peer-to-peer code in a Bare worker.
* **Building a short-lived CLI that runs and exits?** Start from [hello-pear-daemon](/p2p/getting-started/from-a-template/start-from-hello-pear-daemon)—the same standalone binary, but the update check runs in a detached daemon so the command never blocks on the network.
* **Building a terminal app that runs an AI model on the user's machine?** Start from [hello-pear-qvac-tui](/p2p/getting-started/from-a-template/start-from-hello-pear-qvac-tui)—it adds a [QVAC](https://qvac.tether.io) inference worker and a `bare-tui` interface to the hello-pear-bare shape.
* **Building a mobile app?** Start from [hello-pear-react-native](/p2p/getting-started/from-a-template/start-from-hello-pear-react-native)—it embeds a Bare worklet in an Expo/React Native app via [`pear-mobile`](/pear/reference/pear/mobile).

They share the same peer-to-peer core: the [Bare](/bare/reference/bare/modules) runtime, a `pear-runtime`-family module for updates ([`pear-runtime`](/pear/reference/pear/runtime) on desktop and in the terminal, [`pear-mobile`](/pear/reference/pear/mobile) on mobile), and the [Hyperswarm](/p2p/reference/building-blocks/hyperswarm) + [Corestore](/p2p/reference/helpers/corestore) stack. In the worker-based templates—hello-pear-electron, hello-pear-bare, hello-pear-qvac-tui, and hello-pear-react-native—your peer-to-peer logic is portable and only the shell (GUI, terminal, or mobile) changes. hello-pear-daemon has no worker, so its only peer-to-peer code is the update client. See [Runtime and languages](/pear/explanation/runtime-and-languages).

<Callout type="info">
  Once you've cloned a template and made it yours, ship it over the air. For desktop and terminal, [Deploy your application](/pear/how-to/operate-an-app/manual-deployment/deployment) is the step-by-step release flow, and [Release pipeline](/pear/explanation/deployment-releasing-apps-p2p) explains the stage → provision → multisig model behind it. Mobile shares that stage/provision/multisig model but builds a different payload—see [Deploy your mobile application](/pear/how-to/operate-an-app/manual-deployment/mobile).
</Callout>

## More hello-pear repositories [#more-hello-pear-repositories]

Two more repositories sit alongside the templates, but they aren't starting points for a whole app: one is the backend the templates share, the other an early worker-based CLI sample.

<Cards>
  <Card href="https://github.com/holepunchto/hello-pear-worker" title="hello-pear-worker (shared worker)" description="The worker the electron, bare, react-native, and qvac-tui templates embed: pear-runtime or pear-mobile updates, Hyperswarm, Corestore, and framed IPC. Install it from npm or copy it into your app's workers/main.js." />

  <Card href="https://github.com/holepunchto/hello-pear-bare-worker" title="hello-pear-bare-worker (early worker-based CLI)" description="A single-file Bare CLI around the same workers/main.js that hello-pear-bare shipped when it became worker-based in June 2026. Start from hello-pear-bare instead." />
</Cards>

## Where to go next [#where-to-go-next]

* [Build a peer-to-peer chat](/p2p/getting-started/build-a-peer-to-peer-chat/build-a-peer-to-peer-chat)—build the desktop app up from scratch instead of cloning.
* [Pear desktop application architecture](/pear/explanation/pear-desktop-architecture)—the renderer/main/worker model behind the Electron template.
* [Runtime and languages](/pear/explanation/runtime-and-languages)—where Bare and the runtimes fit across desktop, terminal, and mobile.
