Vergate: a version gate for Flutter with force update, soft update and maintenance mode
Description and use
Vergate is a Flutter package that enforces app version policies—force updates, soft updates, and maintenance mode—using a JSON‑based configuration and multiple data sources, reducing duplicated code across projects.
Problem
Developers need a reusable solution to enforce app version policies (force update, soft update, maintenance mode) without rewriting checks for each app.
Outcome
Vergate centralizes version gating logic, reducing code duplication and ensuring consistent update enforcement across Flutter apps.
Workflow
- 1. Add Vergate package to pubspec.yaml.
- 2. Create a VergateController with a data source (e.g., JsonUrlSource).
- 3. Call vergate.start() before runApp().
- 4. Wrap the app with VergateGate to display the gate overlay.
- 5. Configure JSON rules (min_version, latest_version, maintenance window, store links).
- 6. Optionally customize UI or provide a custom source via VergateSource interface.
Evidence
I just published Vergate, a Flutter package that decides whether the installed version of your app may run.
Force update: a dialog that cannot be dismissed, driven by min_version
Soft update: a banner or dialog, driven by latest_version, with "Remind me later" and "Skip this version" remembered between launches
Maintenance mode: an optional from/until window, a live countdown, and an automatic re-check when the window ends
Per-platform rules: separate versions and store links for Android and iOS
Fail-open: network or parsing errors never lock the user out
Re-checks on app resume: users who return from the store get in right away
Vergate does not depend on Firebase or any specific service. The rules are a small JSON document, and it ships with a few ways to load it: JsonUrlSource, CallbackSource, ItunesLookupSource, FallbackSource
The gate is an overlay, not a route, so it works above the Navigator and your app's state is never lost.
There is no store lookup for Android, because Google Play has no official API for it. Put the Android version in your own config.
The update button opens the store page. Android's In-App Update API is not used.
- Record date: 2026-10-03T19:55:53.860Z