The question behind the question
“Build or buy?” is usually asked as a cost question, but the real comparison is between two kinds of cost. Building turns the mesh into engineering work your team owns for as long as the product exists. Buying turns most of it into a license, usage fees for any hosted services, and a dependency on someone else’s roadmap.
Neither is free, and neither number is meaningful until you list what the mesh actually has to do.
What an in-house mesh has to include
Discovery and links on each platform. Two phones can only connect over Bluetooth Low Energy if one advertises and accepts connections while the other scans. Android’s BLE guide states that two devices that only support the central role cannot talk to each other, so each phone needs both roles: CBPeripheralManager and CBCentralManager on iOS, the advertiser, GATT server, and scanner on Android.
Framing. Messages must be split to fit the negotiated link size and reassembled on the other side, with a way to notice missing pieces.
Routing. Forwarding for other devices, with unique message identifiers, a hop limit, and duplicate suppression so traffic does not circle.
Delivery. Acknowledgments, retries with backoff, an outbox that survives restarts, expiry, and clear failure reporting.
Encryption and identity. Device keys, a way to verify them, and end-to-end encryption so relaying phones carry content they cannot read. For groups, a protocol such as MLS (RFC 9420) handles members joining and leaving with forward secrecy and post-compromise security; implementing or integrating it is its own project.
Shared data, if needed. Merge rules for state edited on several devices while apart.
Platform rules. iOS limits what a Bluetooth app can do in the background and documents how its behaviour changes there. Android asks for separate Bluetooth permissions to scan, advertise, and connect from Android 12. Both change between OS releases, so this part is never finished.
Testing is part of the cost
Every part above needs testing on real devices: mixed iPhone and Android pairs, several manufacturers, foreground and background, crowds rather than pairs, and long disconnections. Offline Protocol’s own production guide lists boundaries worth testing whatever you choose:
- internet disconnected while peers keep communicating
- a peer partition, local work, and later reconnection
- process termination and restart with pending records
- queue expiry and capacity exhaustion
- rejected or duplicate business operations
- backend outage, recovery, and reconciliation
An in-house team carries all of this for every OS release. An SDK vendor carries the protocol part, and you still test your own workflow on your own hardware.
What using an SDK costs
SDK costs come in three parts, and vendors combine them differently:
- License. Permissive, copyleft, or commercial terms. Check what your distribution model needs, especially for closed-source apps and app stores.
- Usage fees. Some vendors charge per monthly active user or per message for the SDK itself; others charge only for optional hosted services.
- Integration and testing. Still needed for your own workflow and hardware.
For Offline Protocol, from its live pricing page: the mesh SDK is free under AGPL-3.0-only, including in production, when the product meets the license’s obligations. Closed-source apps, Apple App Store apps, and closed-source firmware need the commercial license, which is annual and has no published price; paid evaluations of one workflow run 4 to 16 weeks and are priced to scope. Traffic that moves device to device over a local transport is never metered on any plan. Hosted services are optional and metered: plans run from Free at $0 to Pro at $99 and Scale at $499 a month, with quotas for OfflineID users, hosted relay deliveries, telemetry events, and location verifications.
How to decide
- List the parts you need. A two-phone handoff needs far less than a group chat across a crowd.
- Estimate each part with your own team, including testing and the ongoing cost of OS changes.
- Price the SDK options on license, usage fees, and the hosted services you would actually use, read from each vendor’s pricing page on the day.
- Weigh control against focus. Building gives full control and full responsibility. Buying lets the team spend its time on the product, at the cost of a dependency.
If the mesh is your product, building may be the point. If it is a feature that keeps your product working when the network fails, weigh the parts list above against the time your team would spend owning it.