How to build a field sales app with Expo and Supabase.
Updated 3 November 2026 · prices checked this month
These are the architecture decisions behind Beatplan, a field sales app that has run a distributor's field team every working day since November 2025. If you are building something similar, they will save you a few months; if you would rather start from working code, Beatplan is for sale.
1. One codebase for phone and web
Expo SDK 58 with React Native renders the iPhone and Android apps and the web console from the same code. Office roles use the web console; field roles use the phone app. Keep web-only screens in their own folder so the native bundle never imports them.
2. Put permissions in the database, not the app
Every table has row-level security, with role checks written as policies against a users table. Hiding a button in the app is cosmetic; the database is what stops a field rep reading another region's payments. Server functions that bypass RLS (SECURITY DEFINER) set their search path and check the caller's role themselves. Users can edit only their own name and phone, enforced with column grants.
3. Design for no signal
Reps work in places with poor coverage. Every write from a field screen goes through an offline queue: if the network is down, the insert or function call is stored and replayed later. Give each row a client-generated UUID so a replay can never create a duplicate.
4. Verify visits, don't just log them
A visit records time, GPS coordinates and an optional photo when the rep checks in. Compare the position with the customer's saved location, and let leads see exceptions rather than every row.
5. Dates in company time
Store calendar dates as YYYY-MM-DD strings computed in the company's time zone. Converting with toISOString in a UTC+5 country moves early-morning visits to the previous day, which breaks daily targets.
6. One settings file for brand and locale
Company name, currency, regions, role labels, activity names and target periods live in one configuration file. Role codes stay fixed in the database; only labels change.
7. Test the security, not just the screens
Beatplan ships 33 automated security tests that install the schema into a temporary database and check what each role can and cannot read or change.
Or start from Beatplan
Beatplan is this architecture, finished: about 55,000 lines of app code, 86 screens, 64 tables, 132 server functions and 163 row-level security rules. Standard licence $2,900; Commercial $4,900 for one client; Agency $12,900 for unlimited clients.
Questions
What stack should I use for a field sales app?
Expo with React Native gives you iPhone, Android and web from one codebase, and Supabase gives you Postgres with row-level security, authentication and edge functions. Beatplan is built on this stack.
How do I handle offline use in a field sales app?
Queue every write made from a field screen when the network is unavailable and replay it later, giving each row a client-generated UUID so replays are idempotent.
See it for yourself
The live demo is the real product with sample data. No sign-up: open it and tap Admin, Director or Accounts.
Prices of other products are taken from their public pricing pages or listings as of November 2026 and may change; check the vendor for current pricing. Product names belong to their owners. Beatplan is not affiliated with them. Beatplan home · All comparisons and guides · Terms · Privacy