This one is quick and easy, but I always forget where it is.
To configure thepassword expiration policy, in the Office 365 admin centre, go to Service Settings > Passwords and configure the expiry policy there. It will apply to all users in your domain.