Email Office 365 users that their AD password is expiring

What is the process for setting up email alert notifications so that users will be notified by email that their Office 365/AD password will soon be expiring and that it needs to be changed?

We are using full Office 365/Active Directory synchronization and have a lot of remote users who never visit our office and therefore never sign into Active Directory on their laptops.

We need to notify users in advance that their Office 365/Active Directory password is expiring and needs to be changed especially since we will be implementing an Active Directory password expiration policy.

If this is something that can't be done natively through Office 365 or Azure then what third party solutions are available that can do this?
IT GuyNetwork EngineerAsked:
Who is Participating?
Vasil Michev (MVP)Connect With a Mentor Commented:
It's easily automated via PowerShell scripts, and there's nothing different here for Office 365 synced users. SImply get one of the dozen examples of scripts available on the internet and run it.

If you have some users that are cloud-only, you will have to use a similar script but via the MSOL cmdlets. Here's an example one:
Éric MoreauSenior .Net ConsultantCommented:
I have too written a powershell script that I run on Sunday mornings.
IT GuyNetwork EngineerAuthor Commented:
Éric Moreau,

Can you please share this powershell script with me?
Éric MoreauSenior .Net ConsultantCommented:
not easily. It is buried into a 300+ lines script which imports 3 other modules! What's wrong with Vasil's script?
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.