Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

erikbbb's avatar

SQLSTATE[HY000] [2054] - authentication method unknown to the client

First, let me apologize. I now there are a lot of threats of these errors.. but none of them worked for me.

My configuration, A fresh new install of:

  • Laravel 5.8
  • Php 7.3
  • Mysql 5.7 (through docker)

I have installed laraval + nova. All the migrations work. The tables are created and through cli i can create a user. But when i want to try the login , i receive this message after i submit the form: URL: http://127.0.0.1:8000/login

 Illuminate \ Database \ QueryException (2054)
 SQLSTATE[HY000] [2054] The server requested authentication method unknown to the client (SQL: select * from 
 `users` where `email` = [email protected] limit 1)

The strange part is, when i changed the database settings in the .env file and clear all cache.. the command 'artisan migrate' through cli failed (like expected), but the error after submitting the loginform is still the same.

It looks like an other connection is used, but how is that possible.. Does someone has a tip to look for?

0 likes
3 replies
erikbbb's avatar

Tnx, i did. but cant find the solution there. i'm using mysql 5.7. Laraval can connect with the database for the migrations.

but through the UI illuminate / doctrine throws an error.. wel maybe i'm to sleepy and read over it. i'll give it a next try tomorrow

erikbbb's avatar

Wel tnx.. i reinstalled laravel / mysql downgraded to 5.7 like they said on github.

but my artisan serve was still running when i used mysql 8.0.

restarting this fixed it .:)

Please or to participate in this conversation.