Most of these algorithms are hashing algorithms, they do not encrypt, they create a hash (checksum), and usually this is the best way to store passwords unless you have a really good reason to recover passwords (and I donβt think there are many reasons).
I typically use sha256. As for salt, random enough 6 or more characters. But salt can be anything; it depends on your imagination how to generate it.
source share