> For the complete documentation index, see [llms.txt](https://learn.farizizwan.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://learn.farizizwan.com/devops-and-devsecops/system-administration-linux/redhat-derivatives/add-user-to-sudoers.md).

# Add User to Sudoers

`Add user to sudo group via usermod`

`$ su root`

`$ usermod -aG wheel username`

Add user to sudo group via visudo

`$ su root`

`$ visudo`

and then insert following after the `%wheel line.`

`username ALL=(ALL) NOPASSWD:ALL`

do not forget to change the `username` to the user of yours.

<figure><img src="/files/0hJaAfsi56cPS1NVHu6d" alt=""><figcaption></figcaption></figure>
