Magento admin login problem

If you can't log in to the admin panel, but no error is shown, then you may have a problem with the session size.

Below is one solution to this problem.

First, check your log files and most likely you will find an error there

main.WARNING: Session size of 262286 exceeded allowed session max size of 256000. [] []

If so, then running the command below will solve your problem

php bin/magento config:set system/security/max_session_size_admin 1024000.

or

php bin/magento config:set system/security/max_session_size_admin 0