> ## Documentation Index
> Fetch the complete documentation index at: https://developer.box.com/llms.txt
> Use this file to discover all available pages before exploring further.

# OAuth 2.0 authentication

> How the OAuth 2.0 flow works on Box, from the authorization URL to the access token your app uses on behalf of a signed-in user.

**REQUIRED GUIDES**

Client-side OAuth 2.0 is one of the easiest ways to authenticate a user for the
Box API. It is an [open standard](https://oauth.net/2/) designed to allow users
to provide applications access to their data in other applications.

If you've ever logged in to a website with Twitter, Facebook, or Google you've
most likely used OAuth 2.0.

![the OAuth 2.0 flow](https://mintcdn.com/box/J_EwM_J-GUl8Mc67/guides/authentication/oauth2/oauth2-flow.png?fit=max\&auto=format\&n=J_EwM_J-GUl8Mc67\&q=85\&s=8c5bce0e44abd018f4a4f19490c56edc)

## How it works

Client-side authentication on Box redirects a user from your application to the
Box web app, where the user logs in and grants your application access to their
data. The flow has four steps:

1. Your application builds an authorization URL from its client ID and a
   registered redirect URI, and sends the user to it.
2. The user logs in to Box and approves the scopes your application asks for.
3. Box redirects the user back to your redirect URI with a short-lived
   authorization code.
4. Your application exchanges that code, along with its client secret, for an
   access token and a refresh token.

Because the token belongs to the person who signed in, your application reaches
exactly the content that user owns or collaborates on, and any content it
creates lives in that user's own account. The
Authentication overview compares this
with the server-side methods.

A free developer account gives you access to the Developer Console, where you can create an OAuth 2.0 application and start authenticating users in minutes.

[https://account.box.com/signup/developer](https://account.box.com/signup/developer)
[https://account.box.com/developers/console](https://account.box.com/developers/console)

> [card] Set up an app with OAuth 2.0

**RELATED GUIDES**
