I was setting up a new WordPress website the other day and encountered a dead loop redirection when trying to log into the backend dashboard /wp-admin/. Scratching my head for a while until I realized that the 8 keys and salt values in the wp-config.php file were set up correctly.
The keys and salts in the configuration file are used to encrypt your credentials before saving them in browser cookies that keep you logged in. For details on what it is and how it works, check out here.
So, how to get a fresh set of keys and salts for any new sites or existing sites? Easy, head over to the salt API, and copy them.