Installation

Usage

The AuthKit React Router SDK provides utilities for integrating AuthKit authentication into React Router 7+ applications.

Refer to the AuthKit documentation for detailed usage instructions and examples.

Beta Versions

Certain WorkOS features may be available only in the beta version of the SDK. Beta versions have the -beta.* suffix, for example, 3.2.0-beta.1. For more information on how to use the beta versions, refer to the README in the GitHub repository.

Releases

December 12, 2025

v0.10.0

Latest
December 12, 2025

What's Changed

  • feat: Add organizationId to onSuccess callback by @nicknisi in #43
  • feat: Add saveSession for manual auth flows by @chaance in #52
  • fix: Unwrap nested data response from React Router by @DennisKraaijeveld in #44

New Contributors

  • @chaance made their first contribution in #48
  • @DennisKraaijeveld made their first contribution in #44
  • @ryanvanoss made their first contribution in #42

Full Changelog: v0.9.0...v0.10.0

September 18, 2025

v0.9.0

September 18, 2025

What's Changed

  • Fix infinite redirects with load balancer TLS termination by @nicknisi in #39
  • Add roles from JWT payload by @atainter in #40
  • v0.9.0 by @atainter in #41

New Contributors

  • @atainter made their first contribution in #40

Full Changelog: v0.8.1...v0.9.0

August 8, 2025

v0.8.1

August 8, 2025

What's Changed

  • fix: use fresh user data when refreshing sessions by @nicknisi in #36

Full Changelog: v0.8.0...v0.8.1

August 5, 2025

v0.8.0

August 5, 2025

What's Changed

  • Fix: Preserve return pathname on session refresh failure by @nicknisi in #31
  • fix: return null user when access token is expired in withAuth by @nicknisi in #32

Full Changelog: v0.7.0...v0.8.0

August 1, 2025

v0.7.0

August 1, 2025

What's Changed

This version implements security improvements to the authentication system.

Changes

  • Modified the authentication data structure to improve security
  • Added a new getAccessToken() function for explicit access to authentication data
  • Updated documentation with security best practices

Breaking Changes

⚠️ This is a breaking change for applications that rely on access tokens being available in loader data.

See the updated README for migration instructions.

Full Changelog: v0.6.1...v0.7.0

June 28, 2025

v0.6.1

June 28, 2025

What's Changed

  • Fix organization ID preservation during token refresh by @nicknisi in #27

Full Changelog: v0.6.0...v0.6.1

June 20, 2025

v0.6.0

June 20, 2025

What's Changed

  • Add support for feature_flags claim by @kkajla12 in #25

Full Changelog: v0.5.0...v0.6.0

June 18, 2025

v0.5.0

June 18, 2025

What's Changed

  • Add Session Refresh Callbacks by @nicknisi in #23
  • Allow configuring session storage on callback route by @nicknisi in #22

Full Changelog: v0.4.1...v0.5.0

May 30, 2025

v0.4.1

May 30, 2025

What's Changed

  • Add withAuth to exports by @nicknisi in #20

Full Changelog: v0.4.0...v0.4.1

May 29, 2025

v0.4.0

May 29, 2025

What's Changed

  • Add withAuth Helper Function by @nicknisi in #16
  • Docs: Fix typo in react router authkit example link by @heatherfaerber in #17

New Contributors

  • @heatherfaerber made their first contribution in #17

Full Changelog: v0.3.0...v0.4.0

April 18, 2025

v0.3.0

April 18, 2025

What's Changed

  • Pin third-party actions to currently used SHA by @nickcollisson-workos in #10
  • Add returnTo argument to signOut method by @nicknisi in #13
  • v0.3.0 by @nicknisi in #14

New Contributors

  • @nickcollisson-workos made their first contribution in #10

Full Changelog: v0.2.0...v0.3.0

April 8, 2025

v0.2.0

April 8, 2025

What's Changed

  • Add switchToOrganization and refreshSession helpers to library by @nicknisi in #11

Full Changelog: v0.1.1...v0.2.0

March 28, 2025

v0.1.1

March 28, 2025

What's Changed

  • fix: pass through non-json responses without modifying the body by @nicknisi in #8
  • v0.1.1 by @nicknisi in #9

Full Changelog: v0.1.0...v0.1.1

March 24, 2025

v0.1.0

March 24, 2025

What's Changed

  • First public release of authkit-react-router
  • add CODEOWNERS, update bug report issue template by @nicknisi in #4

New Contributors

  • @nicknisi made their first contribution in #4

Full Changelog: v0.1.0-alpha.0...v0.1.0

March 11, 2025

v0.1.0-alpha.0

Pre-release
March 11, 2025

This is a prerelease preview of authkit-react-router. If you encounter bugs, please file an issue.

Full Changelog: https://github.com/workos/authkit-react-router/commits/v0.1.0-alpha.0