- Change METHOD of all rows in your pg_hba.conf file from scram-sha-256 to trust
- Add bin folder of Postgres installation to path, if you haven’t
- Open command prompt and enter
psql -U postgres
You won’t be asked for password here. - Enter
\password postgres
- Choose and confirm your password
- Revert pg_hba.conf to original state