This project demonstrates how to implement authentication in a Next.js application using Firebase. Users can create an account and log in using either their Google account or an email/password combination.
- Email/Password Authentication: Users can sign up and log in using their email and password.
- Live previews
- Google Authentication: Users can sign up and log in with their Google account.
- Firebase Integration: Fully integrated with Firebase for user authentication.
Clone the project
git clone https://github.com/alihassnain-github/nextjs-firebase-authentication.gitGo to the project directory
cd nextjs-firebase-authenticationInstall dependencies
npm install- Create a Firebase project at Firebase Console.
- Enable Email/Password Authentication and Google Authentication in the Firebase console.
- Obtain your Firebase config object and add it to your project in ./utils/firebase/config.js.
Install dependencies
npm run devOpen your browser at http://localhost:3000 to see the application in action.
Next.js: Framework for server-side rendering and static web applications.
Firebase: Authentication service to handle user login and registration.
React: Frontend library used in this project.