Skip to main content

Command Palette

Search for a command to run...

Expo Router auth guards that survive expired sessions and deep links

Updated
1 min readView as Markdown
Expo Router auth guards that survive expired sessions and deep links

Most Expo apps get sign-in working on the first day and get auth guards wrong for the next six months. The login screen appears, the token lands in secure storage, and everything looks fine until a user reopens the app from a push notification, lands on a protected screen with an expired session, and sees a flash of someone else's layout — or worse, a blank screen with no way back.

Expo Router gives you the primitives to handle all of this: protected routes, layout-level redirects, and splash screen control that waits for async session restore. The official authentication guide covers the happy path well.


This is an excerpt. Read the full post at otf-kit.dev/blog/expo-router-auth-guards-production — full-stack kits your AI coding agent can actually ship to production. Browse the kits →

More from this blog

O

OTF — kits your AI coding agent can ship to production

540 posts

Engineering notes on shipping production apps with AI coding tools — Claude Code, Cursor, Codex, Lovable, Bolt — and the stack underneath: React Native, Expo, Next.js, Supabase. Honest takes on what works, what breaks, and the full-stack kits that get you to production faster. By OTF.