Cryptographic hashing is used for storing passwords due to its one-way transformation, meaning there is no way to reverse the enciphering. Passwords are disguised and can’t be reversed to their original form.
When hashing, the output is usually 32 characters or more in length, no matter how long the original input is.
Hashing maintains privacy by allowing us to compare if two inputs are the same without knowing the content of the original inputs (the same input will always generate the same output).
The avalanche effect means that the slightest change in the input generates a totally different output. For example, even if a one letter change the resulting hash will be unrecognizable from the original.
There are different types of cryptographic hashing such as SHA-1 and MD5 (not safe anymore), the output length and the method of transformation being the primary way hash functions differ. SHA-256 or bcrypt are more secure.
Securing written communication, hiding words and providing secrecy are the mainly goals of cryptography.