Issue
You receive a "redirect URI mismatch" error when authenticating to Box via API. Click "Show Details" to see which redirect URI is affected.
Root Cause
The most common cause is that the redirect URI in your authentication request doesn't match the redirect URI configured on your app.
Steps to Resolve
To resolve this, you can change the redirect URL used in your application code to strictly match the URL in the developer console, or update the redirect URL in the Box Developer Console configuration tab for your application.
Option 1: Update your Code
For option #1, please modify your application code to replace the impacted URLs to strictly match the URL in the Developer Console.
Option 2: Update your App
For option #2, please use these steps:
- Login to Box as the application owner and navigate to the Box Developer Console
- Click on the application and navigate to the configuration tab
- Scroll down to the "OAuth 2.0 Redirect URI" section
- Update the current URL listed. In the above example, we'd add http://localhost:3000/callback.
Note
If the Redirect URIs section does not appear, your app is not OAuth 2.0 standard, and you’ll need to authenticate differently. See our resources here for next steps: https://developer.box.com/guides/authentication/.