# `requiresLogin`

This configuration option makes all your content private for non-authenticated users.
Only authenticated users, who are verified through either Reunite or an identity provider (IdP) you [added in Reunite](/docs/realm/reunite/organization/sso/add-idp) can access your project.

**Mutually exclusive options**

The `requiresLogin` option cannot be used in conjunction with `rbac`.

## Examples

### Through the `access` object

The recommended way to configure `requiresLogin` is within the `access` object:

```yaml
access:
  requiresLogin: true
```

### Root-level configuration (deprecated)

**Deprecated configuration**

Root-level `requiresLogin` configuration displays warnings when the `access` object is present.
Migrate to the `access` object format.

```yaml
requiresLogin: true
```

## Resources

- **[Access configuration](/docs/realm/config/access)** - Group authentication and access settings together using the `access` object
- **[RBAC configuration](/docs/realm/config/access/rbac)** - Complete options for configuring role-based access control as an alternative to requiresLogin for granular permissions
- **[SSO configuration](/docs/realm/config/access/sso)** - Discover options for configuring single sign-on to work with requiresLogin for streamlined user authentication
