N8n Docker SQLite - Cannot access dashboard after password reset/issue

Describe the problem/error/question

Hi all,
I’m currently running n8n via Docker using a local SQLite database (/home/ageng/n8n-data/database.sqlite). I seem to have lost access to my dashboard after a setup issue.
Here is what I have tried so far:
Verified that my docker-compose.yml is pointing to the correct volume.
Attempted to reset the password via the user-management CLI, but I encountered “Command not found” issues.
Manually edited the user table in database.sqlite using DB Browser for SQLite (clearing the password column).
Added N8N_BASIC_AUTH_ACTIVE=false and N8N_AUTH_CORE_ENABLED=false to my environment variables, but I am still being prompted for authentication.

What is the error message (if any)?

Please share your workflow

(Select the nodes on your canvas and use the keyboard shortcuts CMD+C/CTRL+C and CMD+V/CTRL+V to copy and paste the workflow.)

Share the output returned by the last node

Information on your n8n setup

  • n8n version: Version: 2.27.4
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app): docker
  • Operating system: Linux mint

Hi @Ageng_Prayogi
I think you can try these as the “Command not found” issue likely means you need to run the command inside the container correctly. First, find your container name:

docker-compose ps

Then run the reset with the full correct syntax:

docker exec -u node -it <your-n8n-container-name> n8n user-management:reset

After that, restart Docker and visit your n8n URL you should be presented with a fresh signup screen to create a new owner account. Your workflows will not be affected, but all user accounts will be wiped.

See this:

thank you very much

Hi Ageng,

The “Command not found” error typically happens because the n8n command isn’t in the path of the user you are executing as, or the container environment isn’t initialized for that specific command.

To resolve this and bypass the authentication lock, follow these steps exactly:

  1. Identify your container name: Run docker ps to find the exact name of your running n8n container.

  2. Execute the reset command properly: Run this command from your host machine, ensuring you target the n8n binary path explicitly:

    Bash

    docker exec -it <your-container-name> n8n user-management:reset
    
    

    Bash

    docker exec -it <your-container-name> /usr/local/bin/n8n user-management:reset
    
    
  3. Clean up Environment Variables: Remove the N8N_BASIC_AUTH_ACTIVE and N8N_AUTH_CORE_ENABLED flags from your docker-compose.yml. Manually forcing these to false while the database is expecting an owner account often creates a conflict that keeps you locked out.

  4. Restart: After running the reset, perform a docker-compose down and docker-compose up -d to ensure the instance picks up the changes cleanly. You should then be greeted by the new owner setup screen.

As a best practice for self-hosted instances, I always recommend keeping a secure backup of your database.sqlite file before performing CLI-based user management.

Hope this gets you back into your dashboard!

Best, Swapnil
swapnilailabs.com