Setup

Peach needs no per-app install. You keep starting your app with the command you already use, and Peach connects to that dev server. A config file is optional; add one when you want what it gives you.

If you have not installed Peach yet, follow Installation first.

Expo and bare React Native (Metro)

Start Metro the way you normally do, from your app's project root:

# Expo
npx expo start

# bare React Native
npx react-native start

Then, from the same directory, open the app in Peach:

peach open 8081

Use your server's real port. Without a port, peach open scans for running React Native dev servers and lets you pick one, and a bare peach opens the same picker in the simulator.

Start your dev server from the app's project root. Peach reads your app's configuration from the project root the server advertises, including your Expo app config, custom fonts, splash screen and icon. If the server runs on another machine or names no project root, pass --project-root <app-dir> to peach open; without a project those details may be missing. Your Metro config needs no changes.

One apps (beta)

Start your One app with its usual dev command, then open its port from the app's folder:

peach open <port>

Peach reads the app's icon and widgets from its one() config and compiles the app's Swift and Kotlin sources itself, so your One config needs no Peach plugin.

Check your project first

Before you open an app for the first time, run:

peach compat

It reports the React and React Native your app declares, how much of each native library Peach implements, and any native code Peach does not know, with the config that answers it. Diagnosing your project walks through its output.

peach.config.ts

Most apps need no config. Add a peach.config.ts next to your package.json when you need to answer native code Peach does not know, set environment variables, or pin simulator settings for the app. Peach also accepts peach.config.js, peach.config.mjs and peach.config.cjs.

// peach.config.ts
import type { PeachConfig } from 'peachsim/config'

export default {
  // native modules and views Peach does not know, keyed by package
  packages: {
    'react-native-acme-analytics': 'noop',
  },
  // process.env values your code reads at runtime
  env: { API_URL: 'http://localhost:3000' },
} satisfies PeachConfig

The import is type-only, so the file loads without installing anything. Add peachsim as a dev dependency if you want editor types; peach setup offers to do that for you, along with a peach script in your package.json. Peach reads the file each time it loads your app, so your next reload picks up an edit.

The fields you are most likely to use:

FieldWhat it does
packagesAnswers native modules and views Peach does not know, keyed by the package that asks for them. See Custom stubs.
modulesReplaces a JavaScript module in your bundle with 'noop', an inline value, a project file, or another stub. Use it for packages you do not need in the simulator.
envSets process.env.* inside your app at runtime. Values your bundler inlined at build time, such as EXPO_PUBLIC_*, need a rebuild of the bundle instead.
settingsOverrides simulator settings such as device, appearance and locale for this app.
initialStateSeeds starting state such as locale, color scheme and feature flags.
network.remapRewrites a host:port your app fetches to another one, for suites that hardcode a port already in use on your machine.
runtimeVersionPins the Peach runtime this project runs on. Omit it to use the current stable runtime.
nativeRenderer'fabric' (the default) or 'paper', for apps whose native build turns the New Architecture off.

The Configuration guide shows each slot with worked examples, and the PeachConfig reference lists every type.

Next