For AI agents: fetch the complete documentation index at /llms.txt, the full documentation corpus at /llms-full.txt, the agent skill at /skill.md, or this page as Markdown at /docs/mobile/configuration.md (or send Accept: text/markdown).
Configure the mobile app
Set the backend address and deep-link scheme the native build uses, and keep both sides of the handoff in sync.
Setup and configuration
Put device-facing values in apps/mobile/.env.local; Expo reads that file, not the repository-root .env. EXPO_PUBLIC_API_URL is the Web backend origin the phone can reach — the same value you tested in the phone browser. EXPO_PUBLIC_APP_SCHEME is the app's native URI scheme; use a reverse-DNS value such as com.example.app.
app.json owns the product name, slug, version, bundle identifier, and plugins. app.config.ts derives the deep-link scheme and production origins from EXPO_PUBLIC_APP_SCHEME, so a scheme change needs a native rebuild, not only a Metro restart. On the server, add every origin the app will use to MOBILE_ALLOWED_ORIGINS; the handoff fails closed when the two sides disagree.
Every EXPO_PUBLIC_* value is bundled into the app. Keep provider keys on the server and use public values only for addresses and schemes.
EXPO_PUBLIC_API_URL=http://192.168.1.25:3000
EXPO_PUBLIC_APP_SCHEME=com.example.appImplementation workflow
Restart Expo after changing .env.local. Run the package tests and typecheck, then confirm the resolved scheme with a development build: open an auth callback link and check that it returns to the app instead of the browser. Expo Go cannot validate custom schemes belonging to your native build.
Verification and troubleshooting
Restart Expo after changing .env.local and open the preview on the target device. Change the theme, restart the app, and confirm the choice persists; then trigger a deep link and check that the app routes it instead of the browser.
If you want to continue setup, read Test the mobile app.