Skip to main content

Introduction

Expo Open OTA is an open-source project that allows you to host your own updates server for your Expo application. It is a self-hosted alternative to the official Expo OTA service, implementing the Expo Updates protocol.

warning

Expo Open OTA is not affiliated with Expo. It is an independent open-source project.

How It Works

Expo Open OTA works by redirecting the expo-updates package of your application to a custom OTA server that implements several key endpoints:

1. /manifest

This endpoint is called by the Expo application on launch or when executing checkForUpdateAsync(). The expo-updates package includes several headers in its request:

  • expo-channel-name
  • expo-protocol-version
  • expo-platform
  • expo-runtime-version

Based on these headers, the server determines whether an update is available. The update is retrieved from the branch associated with the given channel in the Expo account.

2. /assets

When an update is available, a list of assets is sent back to the client. These assets are accessed via the /assets endpoint, which:

  • Signs and compresses the files.
  • Returns the required assets to the Expo client.

If a CDN is configured, the returned URL is a pre-signed link pointing to a cdn endpoint. Otherwise, the server returns the asset directly.

3. /requestUploadUrl & /uploadLocalFile

These routes are used by the eoas package to publish updates to the chosen storage solution, whether it's S3 or a local file system. /uploadLocalFile is used to upload the file to the server when storage mode is set to local.

Why Self-Host Your OTA Update server?

There are several reasons why you might want to self-host your updates instead of relying on the official Expo service:

1. Cost Considerations

Expo's pricing model for OTA updates is based on the number of Monthly Active Users (MAUs). For large-scale applications, costs can add up quickly. Below is a brief breakdown of their pricing:

  • 1,000 MAUs: Free
  • Next 199,000 MAUs: $0.005 per MAU
  • Next 300,000 MAUs: $0.00375 per MAU
  • Next 500,000 MAUs: $0.0034 per MAU
  • Next 1,000,000 MAUs: $0.003 per MAU
  • Full pricing details

Self-hosting removes the dependency on Expo's pricing structure, giving you full control over your costs.

2. Full Control Over Your Infrastructure

By hosting your own OTA server, you can:

  • Store update files on your own infrastructure.
  • Secure your files using custom certificates and authentication mechanisms.
  • Ensure compliance with specific security requirements.

3. Custom Network and Security Constraints

One of the key motivations for this project came from my experience at Skeat (skeatapp.com), where we needed to deploy applications within highly controlled network environments. Many of our clients operate in restricted setups where:

  • Internet access is limited.
  • Network traffic must be routed through proxies and VPNs.

Self-hosting an Expo OTA server allows full control over network flows, ensuring seamless deployments even in highly secured environments.

Why Does This Project Rely on Expo?

Although we self-host OTA updates, Expo remains an essential part of our workflow for several reasons:

1. EAS (Expo Application Services) is Great

EAS provides powerful features for building, signing, and submitting applications. These functionalities are industry-standard and difficult to replace, making them worth every penny.

2. Branch & Release Channel Management

We currently use Expo's API to authenticate uploads and manage branch-to-release channel mappings, ensuring smooth versioning and deployment.

3. Potential for Future Independence

At present, this project relies on Expo for managing release channels and branches. However, we aim to implement our own release and versioning logic in the future. This would allow for greater autonomy, reducing dependence on Expo while maintaining flexibility for developers.


By self-hosting Expo Open OTA, you gain the flexibility, security, and control needed for large-scale or restricted-network deployments, while still benefiting from Expo's powerful development tools.