This final part of the Dart Frog Full Course is finally here! 🥳
Hi guys, Samuel here again. Today, will be deploying our secure Todo API (with JWT auth from Part 4) to Globe (globe.dev).
Globe is the go-to deployment platform for Dart & Flutter in 2026. Globe offers zero-config deployment, a global edge network for low-latency worldwide access, automatic scaling, built-in SSL, and first-class support for Dart Frog. No Dockerfiles, no YAML nightmares — just globe deploy, and you’re live.
Why Globe stands out in 2026: It’s purpose-built for Dart ecosystems (integrates natively with Dart Frog, Shelf, Serverpod, etc.), handles cold starts gracefully, and deploys to a distributed edge network (think “hello from any city” demos). Perfect for our full-stack Todo app, test it globally without regional latency issues.
Prerequisites (From Previous Parts)
Dart Frog project from Part 4 (with auth, protected routes, in-memory or simple DB).
Globe account (sign up free at globe.dev).
Globe CLI installed:
dart pub global activate globe_cliLogged in:
globe loginDart Frog CLI (already have from series):
dart pub global activate globe_cliBuild once locally:
dart_frog build(creates optimized production binary in/build).
Step 1: Prepare Your Project for Production
Globe auto-detects Dart Frog projects, but a few tweaks ensure smooth sailing:
-
Listen on the Right Port
Dart Frog defaults to 8080, but Globe uses
PORTenv var. Updatemain.dart(or wherever you serve):
import ‘dart:io’;
import ‘package:dart_frog/dart_frog.dart’;
void main() async {
final port = int.parse(Platform.environment[’PORT’] ?? ‘8080’);
await serve(handler, InternetAddress.anyIPv4, port);
}
-
Secrets & Env Vars
For JWT secret (from Part 4), use Globe’s env vars dashboard instead of hardcoding. Example: In
auth_service.dart, load from env:
final secret = Platform.environment[’JWT_SECRET’] ?? ‘fallback-dev-secret’;
CORS (If Needed)
Already added in Part 3 — Globe handles it fine, but keep wildcard for dev.Build Locally
dart_frog build
This compiles your AOT binary — Globe runs it efficiently.
Step 2: Deploy with Globe CLI
From your project root:
globe deploy
First time? CLI guides you: Create/link project, choose name (e.g., “todo-project”).
Globe detects Dart Frog automatically → applies preset (file-based routing, Shelf under the hood).
Builds & deploys in seconds (AOT binary = fast cold starts).
For production push:
globe deploy --prod
After success:
Get your URL: https://your-project-name.globeapp.dev (or custom domain later).
Test endpoints: Use Postman/curl with your live URL (e.g., https://todo-api-samuel.globeapp.dev/todos with a JWT Bearer token).
Step 3: Post-Deployment Tips
Env Vars: Dashboard > Project > Settings > Environment Variables → Add JWT_SECRET, DB creds, etc.
Scaling & Performance: Auto-scales on demand, edge-cached where possible, great for global users.
Logs & Monitoring: Built-in logs, metrics dashboard.
Custom Domain: Add in settings (SSL auto-provisioned).
CI/CD: Connect GitHub repo for auto-deploys on push.
Costs: Free tier is generous for starters, pay-as-you-scale.
Testing Your Full-Stack App Live
Update Flutter app’s Dio baseUrl to your Globe URL:
final Dio _dio = Dio(BaseOptions(baseUrl: ‘https://your-project-name.globeapp.dev’));
Run Flutter → CRUD Todos securely via live backend. Full-stack Dart in production!
Source Code👇 — Show some ❤️ by starring ⭐ the repo and follow me 😄 https://github.com/techwithsam/dart_frog_full_course_tutorial
Wrapping the Series
From basic intro (Part 1) → CRUD API (Part 2) → Flutter connection (Part 3) → JWT auth (Part 4) → global deployment (Part 5) — you now have a complete, secure, scalable full-stack Dart Todo service.
Globe makes the “deploy” step trivial, letting you focus on building features (next: Add real DB like Postgres via Globe templates?).
What backend are you deploying next? More Dart Frog, Serverpod, or something new? Drop comments below, what feature should we add in a future video?
Thanks for following the 2026 Dart Frog series — subscribe for more full-stack, AI, and trends content. Let’s keep pushing Dart forward! 🚀🐸
Samuel Adekunle, Tech With Sam YouTube
Top comments (0)