From the course: Next.js 14 from Scratch: Build a Real-World Project Using Next.js 14 and MongoDB
Unlock this course with a free trial
Join today to access over 25,200 courses taught by industry experts.
Google OAuth setup - Next.js Tutorial
From the course: Next.js 14 from Scratch: Build a Real-World Project Using Next.js 14 and MongoDB
Google OAuth setup
All right, guys. So we're going to start to get into authentication. And we're going to be using the Google provider with NextAuth. So you do need to get an API key, a client ID, and a Google client secret. So you're going to log into Google and go to console.cloud.google.com. And if you don't already have a project created, create a new one. I'll just create a new one for this. And I'll just call it Property Pulse and Create. So that might just take a second. And I'm going to select that project. You can see that's up here now in this Select box. Then you want to go to APIs and Services and then click on Credentials. So from here, we're going to want to create credentials. So right here. And you want to choose OAuth client ID. So a client ID is used to identify a single app to Google's OAuth servers. That's what we want to do. If your app runs on multiple platforms, each will need its own client ID. So we're going to click on this Configure Consent screen. Here we're going to click…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.