Overview
There are two ways to set up the Omi app for development:Automatic Setup
Manual Setup
Prerequisites
Before starting, make sure you have the following installed:Flutter SDK
Xcode
Android Studio
CocoaPods
npx). make dev-up names any of these that are missing.Build the App Automatically
This is the recommended way to get started.setup.sh builds the dev flavor
against the local backend harness — the Python API on port 8000 and the
Firebase Auth emulator on port 9099, using the demo-omi-local Firebase
project. iOS builds address them as 127.0.0.1; Android builds default to the
emulator’s host alias 10.0.2.2.
Video Walkthrough
Setup Steps
Start the local backend harness
make dev-init builds backend/.venv from whatever python3 resolves to,
and the backend requires Python 3.11 — make sure that’s what you get, or
the harness fails later with import errors.No provider API keys? Use fake providers instead:make dev-status, and stop it later with
make dev-down. Ports, seeded local users, and troubleshooting live in the
local emulator runbook.Navigate to the app directory
Run setup for your platform
- iOS
- Android
Run in simulator
- Xcode: Open
app/iosfolder - Android Studio: Open
app/androidfolder
Build the App Manually
Manual setup gives you full control, allowing you to use your own backend.Verify Flutter Installation
Example output
Example output
Recommended versions
Recommended versions
app/setup.sh for recommended versions:- Flutter 3.44.5
- Xcode 16.4
- Android SDK Platform 35
- NDK 28.2.13676358
- JDK 21
Get Flutter Dependencies
app directory, install packages:Install iOS Pods
Configure Environment
Add API Keys
.dev.env and add your API keys:Run Build Runner
Setup Firebase
- Follow the official Firebase Flutter Setup through Step 1
- For Apple login, create an identifier first
- Configure
flutterfire configusing your own bundle IDs and your own project — not Omi’s - Generate SHA1/SHA256 keys for your keystore and add them to Firebase (StackOverflow guide | Official Docs)
Run the App
Code Formatting
We usedart format with a line length of 120 characters.
To automatically format code on commit, install the pre-commit hook:
Troubleshooting
Flutter doctor shows issues
Flutter doctor shows issues
- Run
flutter doctor -vfor detailed output - Follow the suggestions to fix each issue
- Make sure all required SDKs are installed
iOS build fails
iOS build fails
- Ensure CocoaPods is installed:
sudo gem install cocoapods - Run
pod installin theiosdirectory - Try
pod repo updateif dependencies fail
Android build fails
Android build fails
- Check NDK is installed via Android Studio SDK Manager
- Verify JDK version matches requirements (JDK 21)
- Accept all Android licenses:
flutter doctor --android-licenses
Firebase auth not working
Firebase auth not working
- Enable Google/Apple sign-in in Firebase Console
- Verify SHA1/SHA256 keys are added to Firebase
- Check bundle IDs match your Firebase configuration
App can't reach the backend (connection refused / timeouts)
App can't reach the backend (connection refused / timeouts)
setup.sh builds against http://127.0.0.1:8000 but does not start anything.
Run make dev-up from the repo root first, and confirm with make dev-status.On a physical device, 127.0.0.1 is the phone — set OMI_DEV_HOST to your
Mac’s LAN or Tailscale address before running both setup.sh (so the
build points at your machine) and make dev-up (so the harness actually
listens there — it defaults to loopback-only otherwise, which is why a
device build alone used to reach nothing). Export it in the same shell so
both commands see it. The Android emulator uses 10.0.2.2 by default.Sign-in works but every request returns 401
Sign-in works but every request returns 401
API_BASE_URL points at a backend
initialized for a different project. Point API_BASE_URL at a backend that
verifies against your project.Omi’s shared https://api.omiapi.com/ is never a valid target for a
self-configured build — it verifies against Omi’s own Firebase project, and
the demo-omi-local configs setup.sh installs are emulator-only fakes that
no hosted backend can verify. Production data requires the explicit beta
profile.iOS: Unable to flip between RX and RW memory protection
iOS: Unable to flip between RX and RW memory protection
-
Use iOS Simulator (Recommended for Development):
- In Xcode, select an iOS Simulator (e.g., “iPhone 16 Pro”) instead of your physical device
- The simulator doesn’t have this restriction, so Debug mode works normally
- Or run:
flutter run --flavor dev(it will use a simulator if available)
-
Use Release/Profile Mode for Physical Devices:
- If you need to test on a physical device, build in Release or Profile mode:
- Or in Xcode, select “Release” or “Profile” scheme instead of “Debug”
- If you need to test on a physical device, build in Release or Profile mode: