
auth0-react
Adding Auth0 login, logout, protected routes, or user sessions to a React SPA
by auth0Free
Description
The auth0-react skill helps an agent add Auth0 login, logout, protected routes and user sessions to a React single-page app, using the @auth0/auth0-react SDK. It supports React 16.11 and later, including React 18 and 19, in apps built with Vite or Create React App. You need an Auth0 account with an application set up. If you do not have one yet, the skill points you to the auth0-quickstart skill first. The skill lists when not to use it. Next.js apps should use the auth0-nextjs skill, React Native apps the auth0-react-native skill, and server-side rendered React needs a framework-specific SDK. The SDK uses Auth0 Universal Login with redirects, so it does not offer embedded login. For backend API authentication, the skill recommends express-openid-connect or JWT validation. It is published by Auth0 in the agent-skills repository on GitHub. Install it with: npx skills add https://github.com/auth0/agent-skills --skill auth0-react.…
Highlights
- Auth0 login and logout for React SPAs
- Protected routes and user sessions
- Supports React 16.11 through 19
- Points to the right skill for Next.js and React Native
- Install with npx skills add
Ratings & Reviews
No ratings yet
Be the first to rate auth0-react.
People also visit
auth0-react FAQ
What does the skill set up?
Login, logout, protected routes and user sessions in a React single-page app, using @auth0/auth0-react.
What do I need first?
A React 16.11 or later app made with Vite or Create React App, and an Auth0 account with an application configured.
Can it do embedded login?
No. The SDK uses Auth0 Universal Login, which is redirect-based.
How do I install it?
Run npx skills add https://github.com/auth0/agent-skills --skill auth0-react.
What are the security audit results?
Gen Agent Trust Hub: Pass. Socket: Pass. Snyk: Warn.
What are the best auth0-react alternatives?
Popular alternatives to auth0-react include auth0-nextjs, clerk-react-patterns and auth0. See all auth0-react alternatives















