Office 365 – Set user password to never expire

Update 2017

There is no need to mess with PowerShell commands anymore. You can set passwords to never expire in Office 365 admin GUI:

  • Settings > Security & Privacy > Password Policy > Edit > Set user password to never expire.

 


 

Original Article

Get-MSOUser

To set user password to never expire on Microsoft Exchange Online / Office 365 service perform following:

  • Install tools required to connect to Windows Azure AD (More info…)
    • Microsoft Online Services Sign-in Assistant. Download link
    • Windows Azure Active Directory Module for Windows PowerShell. 32bit or 64bit

  • Launch Windows Azure Active Directory Module for Windows PowerShell and run following commands:
    • Connect-msolservice
      Provide your Office 365 admin username and password
    • Get-MSOLUser | Select UserPrincipalName, PasswordNeverExpires
      Check current PasswordNeverExpires setting for all users
    • Set-MsolUser -UserPrincipalName <user ID> -PasswordNeverExpires $true
      Set password to never expire for a singe user
    • Get-MSOLUser | Set-MsolUser -PasswordNeverExpires $true
      Set password to never expire for all users

02.2014
Office 365
Exchange Online
Windows 7 SP1


Comments

Leave a Reply

Your email address will not be published. Required fields are marked *

Captcha
captcha
Reload