# NOPERM: The ACL user lacks permission

> The connection authenticated as an ACL user whose rules do not cover this command, key pattern or channel, so Redis refuses it.

Source: https://sqlly.app/errors/redis/noperm
Last updated: 2026-11-30
License: Text and data [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/) (credit SQLly, sqlly.app); code and SQL snippets [MIT](https://opensource.org/license/mit). [Details](https://sqlly.app/license).
Note: Quoted error message text belongs to its database vendor.

- Error prefix: `NOPERM`
- Category: Connection and auth

Error message:

```text
NOPERM User default has no permissions to run the 'get' command
```

## What it means

Since Redis 6, permissions are per user in the ACL system. A connection can be fully authenticated and still be refused when the command is not in the user's command set, the key does not match the user's key patterns, or, for pub/sub, the channel is not allowed. A command refusal names the user and the command. A key refusal reads `NOPERM No permissions to access a key` on Redis 8.0 and names neither the user nor the key, so check ACL LOG for the user and key.

It is the least dramatic of the auth errors: the login works, the first refused command does not. It shows up after someone tightens a user to least privilege and misses a command, after key patterns were written for an old naming scheme, and when occasional jobs call commands outside the new set.

## Common causes

- The user's command rules, such as +@read or +get, do not include the command the application calls.
- The key does not match the user's ~pattern, so an otherwise permitted command is refused on that key.
- The user was rotated to a narrower rule set and a batch job or admin tool still calls commands outside it.

## How to fix it

1. Inspect the user's effective permissions:

   ```sql
   ACL GETUSER app
   # flags, key patterns, channels, command rules
   ACL LIST
   ```
2. Grant the missing command or category, scoped as narrowly as the app needs:

   ```sql
   ACL SETUSER app ~cache:* +get +set +del
   ```
3. Verify as that user, not as admin, so the test matches what production does:

   ```sql
   AUTH app s3cret
   GET cache:user:1000
   ```

## Reproduce it safely

```sql
redis-server --port 7305 --save '' &
redis-cli -p 7305 ACL SETUSER app on '>s3cret' '~cache:*' '+get'
redis-cli -p 7305 --user app --pass s3cret GET cache:x
# (nil) - allowed
redis-cli -p 7305 --user app --pass s3cret SET cache:x 1
# (error) NOPERM User app has no permissions to run the 'set' command
```

## How SQLly helps

When a connection SQLly tests authenticates but a query is refused, the full NOPERM line appears in the results pane with the user and command named, and ACL GETUSER and ACL LOG run from the editor to show exactly which rule is missing.

## Questions

### The user has +@read, why is GET still refused?

Commands and key patterns are separate checks: both must match. A user with +@read whose patterns do not cover the key still gets NOPERM.

### Where does Redis record these refusals?

ACL LOG keeps the recent security events. For a command refusal the object is the command name; for a key refusal it is the key. ACL LOG RESET clears the list.

## Related errors

- [`NOAUTH`](https://sqlly.app/errors/redis/noauth): Authentication required
- [`1142`](https://sqlly.app/errors/mysql/1142): MySQL: Command denied to user for table
- [`42501`](https://sqlly.app/errors/postgresql/42501): PostgreSQL: permission denied
- [`229`](https://sqlly.app/errors/sql-server/229): SQL Server: Permission denied on object

The code and message text are from the [Redis documentation and source code](https://redis.io/docs/latest/).
