NE

nextjs-supabase-auth

Handles Supabase Auth integration for Next.js App Router projects securely.

Install

mkdir -p .claude/skills/nextjs-supabase-auth && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/879" && unzip -o skill.zip -d .claude/skills/nextjs-supabase-auth && rm skill.zip

Installs to .claude/skills/nextjs-supabase-auth

Activation

This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.

Expert integration of Supabase Auth with Next.js App Router Use when: supabase auth next, authentication next.js, login supabase, auth middleware, protected route.
163 chars✓ has a “when” trigger
Intermediate

Key capabilities

  • Manages OAuth callback exchanges
  • Configures secure cookie-based session state
  • Implements middleware-level route protection
  • Wraps server-side authentication logic in Server Actions

How it works

Injects authentication logic into the Next.js lifecycle, primarily through middleware handling of session tokens and secure cookie storage.

Inputs & outputs

You give it
Auth provider choice and protected route paths
You get back
Configured middleware and auth-guarded route logic

When to use nextjs-supabase-auth

  • Protecting routes in Next.js with Supabase
  • Implementing login functionality via Server Actions
  • Handling auth callbacks in Next.js
  • Configuring auth middleware for session refreshing

About this skill

Next.js + Supabase Auth

You are an expert in integrating Supabase Auth with Next.js App Router. You understand the server/client boundary, how to handle auth in middleware, Server Components, Client Components, and Server Actions.

Your core principles:

  1. Use @supabase/ssr for App Router integration
  2. Handle tokens in middleware for protected routes
  3. Never expose auth tokens to client unnecessarily
  4. Use Server Actions for auth operations when possible
  5. Understand the cookie-based session flow

Capabilities

  • nextjs-auth
  • supabase-auth-nextjs
  • auth-middleware
  • auth-callback

Requirements

  • nextjs-app-router
  • supabase-backend

Patterns

Supabase Client Setup

Create properly configured Supabase clients for different contexts

Auth Middleware

Protect routes and refresh sessions in middleware

Auth Callback Route

Handle OAuth callback and exchange code for session

Anti-Patterns

❌ getSession in Server Components

❌ Auth State in Client Without Listener

❌ Storing Tokens Manually

Related Skills

Works well with: nextjs-app-router, supabase-backend

When not to use it

  • Implementing basic local password authentication without a backend
  • Building static websites without server-side routing

Prerequisites

Next.js App RouterSupabase backend

Limitations

  • Requires Supabase as the identity provider
  • Strict adherence to App Router architecture
  • Cannot bypass client-side session listener requirements

How it compares

Automates the wiring between Next.js server components and Supabase, bypassing manual boilerplate implementation for token management.

Compared to similar skills

nextjs-supabase-auth side by side with the closest alternatives in the catalog.

SkillInstallsUpdatedSafetyDifficulty
nextjs-supabase-auth (this skill)126moNo flagsIntermediate
app-specific-patterns42moNo flagsIntermediate
javascript-typescript-typescript-scaffold34moReviewBeginner
nuxt-better-auth16moNo flagsIntermediate

Try saying

Example prompts that trigger this skill in your AI assistant.

software-architecture

davila7

Guide for quality focused software architecture. This skill should be used when users want to write code, design architecture, analyze code, in any case that relates to software development.

333868

planning-with-files

davila7

Implements Manus-style file-based planning for complex tasks. Creates task_plan.md, findings.md, and progress.md. Use when starting complex multi-step tasks, research projects, or any task requiring >5 tool calls.

233106

telegram-bot-builder

davila7

Expert in building Telegram bots that solve real problems - from simple automation to complex AI-powered bots. Covers bot architecture, the Telegram Bot API, user experience, monetization strategies, and scaling bots to thousands of users. Use when: telegram bot, bot api, telegram automation, chat bot telegram, tg bot.

106130

scroll-experience

davila7

Expert in building immersive scroll-driven experiences - parallax storytelling, scroll animations, interactive narratives, and cinematic web experiences. Like NY Times interactives, Apple product pages, and award-winning web experiences. Makes websites feel like experiences, not just pages. Use when: scroll animation, parallax, scroll storytelling, interactive story, cinematic website.

101142

humanizer

davila7

Remove signs of AI-generated writing from text. Use when editing or reviewing text to make it sound more natural and human-written. Based on Wikipedia's comprehensive "Signs of AI writing" guide. Detects and fixes patterns including: inflated symbolism, promotional language, superficial -ing analyses, vague attributions, em dash overuse, rule of three, AI vocabulary words, negative parallelisms, and excessive conjunctive phrases. Credits: Original skill by @blader - https://github.com/blader/humanizer

90175

game-development

davila7

Game development orchestrator. Routes to platform-specific skills based on project needs.

70195

You might also like

app-specific-patterns

growilabs

GROWI main application (apps/app) specific patterns for Next.js, Jotai, SWR, and testing. Auto-invoked when working in apps/app.

46

javascript-typescript-typescript-scaffold

sickn33

You are a TypeScript project architecture expert specializing in scaffolding production-ready Node.js and frontend applications. Generate complete project structures with modern tooling (pnpm, Vite, N

31

nuxt-better-auth

onmax

Use when implementing auth in Nuxt apps with @onmax/nuxt-better-auth - provides useUserSession composable, server auth helpers, route protection, and Better Auth plugins integration.

11

server-actions

davepoon

This skill should be used when the user asks about "Server Actions", "form handling in Next.js", "mutations", "useFormState", "useFormStatus", "revalidatePath", "revalidateTag", or needs guidance on data mutations and form submissions in Next.js App Router.

11

web-frameworks

mrgoonie

Build modern full-stack web applications with Next.js (App Router, Server Components, RSC, PPR, SSR, SSG, ISR), Turborepo (monorepo management, task pipelines, remote caching, parallel execution), and RemixIcon (3100+ SVG icons in outlined/filled styles). Use when creating React applications, implementing server-side rendering, setting up monorepos with multiple packages, optimizing build performance and caching strategies, adding icon libraries, managing shared dependencies, or working with TypeScript full-stack projects.

10

zod-validation-expert

TJSNDHU

Expert in Zod — TypeScript-first schema validation. Covers parsing, custom errors, refinements, type inference, and integration with React Hook Form, Next.js, and tRPC.

00

Search skills

Search the agent skills registry