WhatsApp Now: +977-9802857085

@shisupaila

Babyland Joy
NEWS PANEL

News Updates

Thoughts, inspiration and insights from the Shisupaila team.

1️⃣ How I Implemented Email or Phone Authentication in Django

1️⃣ How I Implemented Email or Phone Authentication in Django

Authentication is one of the most important parts of any web application. In many real-world systems, users prefer logging in using either their email address or phone number instead of just a username. In this project, I implemented a custom authentication backend in Django that allows users to log in using email or phone number. I used Django’s BaseBackend and get_user_model() to keep the solution flexible and future-proof. The backend checks whether the input matches the user’s email or username and then verifies the password securely using Django’s built-in hashing system. This approach improves user experience while keeping the system secure. Through this implementation, I learned how Django authentication works internally and how to extend it for real-world requirements.

Link →