Fix login when wrapping a web app for iOS
Going native broke authentication three ways · Reddit r/lovable · u/LibrarianOk1263 · Mar 2026
What happened
Wrapping a Lovable web app for iOS meant magic links opened Safari, Google OAuth was blocked in the web view, and Apple required Sign in with Apple.
The honest numbers
- Says 8 months from web app to App Store review
As stated by the source. Not independently verified.
The lesson
If you plan to go to the App Store, check the login rules early. Web login often doesn't work inside a native wrapper.
Fix prompt for your own AI tool
Copy this into your own AI tool (Cursor, Lovable, Claude Code, Bolt…). It's general guidance written by us. Review what the AI suggests before applying it.
I'm a beginner building an app with Lovable. Please review how login, sessions and access control work in my project. 1) Explain in plain English how a user signs in, how long a session lasts and what happens on logout. 2) Check that sessions expire, that logout really ends the session on the server, and that every API route and database query checks the user is allowed to see that data (not only the UI). 3) List each problem you find with the file name and a suggested fix, most serious first. 4) Give me a short manual test plan: log in, log out, wait for expiry, and try to open another user's data with a second account. Don't change anything until I've approved your plan. Never ask me to paste API keys, passwords or .env contents; tell me where to check them myself.
Why this keeps happening: auth, sessions & access
AI tools generate sign-up and login screens quickly, but the hard parts are invisible in a demo: session expiry, real logout, password reset, and checking on the server that a user may see the data they ask for.
A quick checklist before you ship
- Test logging out, then pressing back and refreshing: you should not see private pages.
- Create a second account and try to open the first account's records by changing IDs in the URL or request.
- Check that every API route and database query verifies the user, not only the UI.
- Test native and social login on a real device before launch.
More on this: every auth, sessions & access story and our related guide.
Tools involved
Lovable stories, Supabase stories, RevenueCat stories, Stripe stories, Vercel stories
Related stories
- Check a Lovable app for exposed user records
Lovable-hosted app exposed 18,697 user records - Harden a vibe-coded app before launch
Vibe-coded app hacked twice in its first days - Check your AI-built app for the top flaws before launch
Redproof read 1,029 AI-built apps: 62% of Lovable, Bolt and v0 apps had a high or critical flaw, against 20% of Cursor and Claude Code projects
Source: original post on Reddit r/lovable ↗. Summarised in our own words; numbers are as stated by the source. Browse all stories.