Standalone vs Integrated Authentication: Which is Better?

0
9
Asked By TechSavvyNinja21 On

I'm exploring options for authentication management and I'm stuck between two choices. I've heard that it's generally not advisable to run your own authentication system, so I've narrowed it down to: 1) Using Better-Auth as a standalone backend service just for auth, or 2) Hosting Zitadel myself. I'm familiar with Better-Auth from previous projects, but I usually integrated it within my backend. Now, I want a standalone auth service to maintain consistency across various backends. Zitadel looks promising but seems to require less setup, though I wonder if that comes at the cost of flexibility. Can anyone share their experiences with these platforms and give recommendations on which one to choose and why?

5 Answers

Answered By UserSensei On

Honestly, just integrate the auth with your backend. Most mature frameworks have solid built-in user management. It's surprising to see people reinvent the wheel for something that has been well established for years.

Answered By CodeGuru99 On

If you're already comfortable with Better-Auth, I'd say stick with it. It's a mature solution and probably won't limit you. Just a heads up: make sure to use argon2 for encryption instead of bcrypt since the latter is a bit outdated. If you're open to alternatives, Pocketbase could work just for auth, but it's a bit less stable right now.

Answered By PrivacyNerd On

For self-hosted options, Keycloak is another solid choice if you're considering. And regarding the whole running-your-own-auth debate, it really boils down to your specific needs. If you foresee needing multiple projects to use the same auth, then a third-party provider might work better.

Answered By DevOpsWhiz On

I’ve implemented both options in production and here’s what I think: Better-Auth as a standalone service is great when you need multiple apps accessing the same auth. You’ll have a singular point for user identity which simplifies adding new applications. That said, you do introduce more complexity since you'll need a dedicated deployment pipeline for that service.

For a single app, you might be overcomplicating things. Keeping it integrated would reduce latency and potential failure points.

Answered By SecureMyApp On

I recommend avoiding building your own auth solution. It can take time away from your main product, and if it breaks, it can seriously impact your app. Check out services like Auth0 or Supabase. Auth0 has a free plan that could work for you initially. Just assess your needs based on your future plans.

Related Questions

LEAVE A REPLY

Please enter your comment!
Please enter your name here

This site uses Akismet to reduce spam. Learn how your comment data is processed.