Clerk React Router SDK
The Clerk React Router SDK is built on top of the React SDK and is the recommended method for integrating Clerk into your React Router application.
Client-side helpers
The React Router SDK provides access to all of Clerk React's hooks which give you access to the Clerk
object and a set of useful helper methods for signing in and signing up. Learn more in the React SDK reference.
Server-side helpers
The following references show how to integrate Clerk features into applications using React Router server functions and API routes.
Auth
object
The getAuth()
method returns an Auth
object. This JavaScript object contains important information like the current user's session ID, user ID, and organization ID. Learn more about the Auth
object.
React Router implementations
React Router can be integrated with Clerk in two ways:
- As a framework (recommended): Configure your app using Clerk's React Router SDK
- As a library: Manually integrate React Router into your React + Vite app using library mode
Feedback
Last updated on