In Office 365, I have a workflow that runs in the context of another user - a service user. The service users password gets expired after 120 days and then has to be edited, like it does for all other users. I want to set the password policy for this specific service user to never expire.

In office 365 I have clicked around a bit and have only found how to set the password policy for all users, but not how to set password policy for an individual user.

Can password policy be set for one spesific user via Office 365 admin GUI without affecting all other users?

1 Answer 1


For Office 365 Enterprise and MidSize Business you can set a users Password to never expire using

  1. Connect to Windows PowerShell by using your company admin credentials. Run the following cmdlet:

  2. Do one of the following:

    To set the password of one user to never expire, run the following cmdlet by using the UPN or the user ID of the user:

    Set-MsolUser -UserPrincipalName <user ID> -PasswordNeverExpires $true


  • Hi Amal. How can I run powershell with my company admin credentials ? I have tried with "run as different user" , but it results with "There are currently no logon servers available to service the logon request".
    – Ilyas
    Commented Apr 7, 2015 at 14:13
  • 1
    Check my article amalhashim.wordpress.com/2015/01/05/… .. Commented Apr 7, 2015 at 14:14
  • Thanks for the tips, Amal, I installed the SharePoint Online Management Shell, and tried this command: Connect-SPOService -Url https://< url of intranet > -Credential [email protected], but get this exception: Connect-SPOService : Current site is not a tenant administration site. Please advice.
    – Ilyas
    Commented Apr 7, 2015 at 18:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.