Skip to main content
CourseFlix

NestJS Authentication + Refresh Token With Passport.js

2h 29m 25s
English
Paid

In this lesson, you add JWT auth to a NestJS app. You also set up refresh tokens. These tokens help you keep users logged in without a new login each time.

What You Build

You link a NestJS backend to a Next.js client. You protect routes with custom middleware. You also add Google OAuth for quick sign‑in. Each part works together to form a clear auth flow.

Key Steps

  • Create JWT access and refresh tokens.
  • Store and check refresh tokens in the backend.
  • Protect routes with Passport.js guards.
  • Use Google OAuth for a simple login option.
  • Connect these features to a Next.js front end.

Why It Matters

This setup gives your app safe login behavior. You learn how to handle tokens, guard routes, and link auth across services. These skills help you build full‑stack apps that users can trust.

Additional

  • Backend: https://github.com/mguay22/nestjs-social-auth-refresh
  • UI: https://github.com/mguay22/nextjs-social-auth-refresh

About the Author: Michael Guay

Michael Guay thumbnail

Michael Guay is a US software engineer and prolific independent instructor publishing course material on the .NET / C# stack and the modern web frameworks adjacent to it.

The course catalog covers C# and .NET fundamentals, ASP.NET Core for back-end development, Entity Framework for data access, Blazor for full-stack C# web applications, plus the surrounding tooling and deployment patterns. The teaching style is patient and project-oriented, with each course typically building a working application end-to-end.

The CourseFlix listing under this source carries over 20 Michael Guay courses spanning that range. Material is paid and aimed at developers picking up the .NET stack or extending their existing .NET experience into newer parts of the platform.

Watch Online 1 lessons

This is a demo lesson (10:00 remaining)

You can watch up to 10 minutes for free. Subscribe to unlock all 1 lessons in this course and access 10,000+ hours of premium content across all courses.

View Pricing
0:00
/
#1: NestJS Authentication + Refresh Token With Passport.js
All Course Lessons (1)
#Lesson TitleDurationAccess
1
NestJS Authentication + Refresh Token With Passport.js Demo
02:29:25
Unlock unlimited learning

Get instant access to all 0 lessons in this course, plus thousands of other premium courses. One subscription, unlimited knowledge.

Learn more about subscription

Course content

1 lessons · 2h 29m 25s
Lessons
  1. 1 NestJS Authentication + Refresh Token With Passport.js 02:29:25

Related courses

  • NestJS - Building Real Project API From Scratch thumbnail

    NestJS - Building Real Project API From Scratch

    By: Udemy, MonsterLessons (Oleksandr Kocherhin)
    In this course we will build a Medium clone API using NestJS, Typescript, Typeorm and PostgreSQL. This course is fully focused on fast and deep dive into creati
    7 hours 59 minutes 44 seconds
  • React, NextJS and NestJS: A Rapid Guide - Advanced thumbnail

    React, NextJS and NestJS: A Rapid Guide - Advanced

    By: Udemy
    React with Typescript, Next.js, Redux, NestJS, Docker, Redis, Stripe, Frontend & Backend Filtering. Learn how to create an Ambassador App using React, NextJS an
    8 hours 40 minutes 51 seconds 0 / 5
  • React and NestJS: A Practical Guide with Docker thumbnail

    React and NestJS: A Practical Guide with Docker

    By: Udemy
    React and NestJS: A Practical Guide with Docker — build a fullstack TypeScript app with React, NestJS, TypeORM, and containerized deploy.
    6 hours 54 minutes 20 seconds

Frequently asked questions

What is NestJS Authentication + Refresh Token With Passport.js about?
In this lesson, you add JWT auth to a NestJS app . You also set up refresh tokens. These tokens help you keep users logged in without a new login each time. What You Build You link a NestJS backend to a Next.js client. You protect routes…
Who teaches NestJS Authentication + Refresh Token With Passport.js?
NestJS Authentication + Refresh Token With Passport.js is taught by Michael Guay. You can find more courses by this instructor on the corresponding source page.
How long is NestJS Authentication + Refresh Token With Passport.js?
NestJS Authentication + Refresh Token With Passport.js contains 1 lesson with a total runtime of 2 hours 29 minutes. All lessons are available to watch online at your own pace.
Is NestJS Authentication + Refresh Token With Passport.js free to watch?
NestJS Authentication + Refresh Token With Passport.js is part of CourseFlix's premium catalog. A CourseFlix subscription unlocks the full video player; the course description, table of contents, and preview information are available to everyone.
Where can I watch NestJS Authentication + Refresh Token With Passport.js online?
NestJS Authentication + Refresh Token With Passport.js is available to watch online on CourseFlix at https://courseflix.net/course/nestjs-authentication-refresh-token-with-passport-js. The page hosts every lesson with the integrated video player; no download is required.