# Authelia

Authelia is an open-source authentication and authorization server providing two-factor authentication and single sign-on (SSO) for your applications via a web portal. It acts as a companion for reverse proxies by allowing, denying or redirecting requests.

<ServiceNotice serviceName="Pocket ID" linkPath="/guides/docker/apps/traefik" />

### References

<ReferenceLinks references={frontmatter.references} />

---

## Make directory

```sh wrap preserveIndent
mkdir -p {{DOCKER_PATH_VAR}}/authelia && cd {{DOCKER_PATH_VAR}}/authelia
```

## compose.yml

```sh
nano compose.yml
```

```yml title="compose.yml"
dockerCompose
```

## configuration.yml

```sh
mkdir authelia && nano ./authelia/configuration.yml
```

```yml title="./authelia/configuration.yml"
configuration
```

## users-database.yml

```sh
mkdir authelia && nano ./authelia/users-database.yml
```

```yml title="./authelia/users-database.yml"
usersDatabase
```

## Start container

```sh
docker compose up -d
```

## Open web ui

<OpenWebUI port="9091" />

## Nginx Proxy Manager

- Create a Proxy Host in NPM for `auth.lan.your-domain.tld` pointing to authelia port `9091`.
- For every service you want to protect:
  - Open the Proxy Host in NPM.
  - Go to the Advanced tab.
  - Paste this snippet.

```txt
npmService
```
