# YT DLP

## Downloading Videos

Download the best quality video:

```bash
yt-dlp -f "bv+ba/b" https://...
```

Download a playlist:

```bash
yt-dlp -f "bv+ba/b" --write-thumbnail 'https://www.youtube.com/watch?v=l-unefmAo9k&list=PLuYLhuXt4HrQqnfSceITmv6T_drx1hN84'
```

## Authentication

To download age restricted videos:

1. Log into youtube via chromium
2. Pass `--cookies-from-browser chromium` as part of yt-dlp

```bash
yt-dlp -f "bv+ba/b" --write-thumbnail --cookies-from-browser chromium 'https://youtu.be/2YkEDGD_sDs?si=YQSfjv8Xhk23lvc3'
```
