The password hashing API provides an easy to use wrapper around crypt() to make it easy to create and manage passwords in a secure manner.
This extension is available since PHP 5.5.0 but there is also an » userland implementation for PHP >= 5.3.7.