Revoke-SPOUserSession

Provides IT administrators the ability to invalidate a particular users' O365 sessions across all their devices.

Syntax

Revoke-SPOUserSession
      [-User] <String>
      [-Confirm]
      [-WhatIf]
      [<CommonParameters>]

Description

You must be a SharePoint Online global administrator to run the cmdlet.

Requires a valid Connect-SPOService context to identify the tenant. For information about how to connect to the tenant, see Connect-SPOService.

When the cmdlet is ran the following will occur:

User will be signed out of browser, desktop and mobile applications accessing Office 365 resources across all devices.

Will not be applicable for guest users.

Possible results for this cmdlet are:

Results Reason

Warning : We couldn't find the user@contoso.com. Check for typos and try again. Invalid input for -User parameter.

We successfully signed out from all devices. Successful instantaneous revocation.

It can take up to an hour to sign out from all devices. Successful non-instantaneous revocation.

Sorry, something went wrong and we couldn't sign out from any device. The cmdlet did not successfully execute.

The cmdlet will be available in the future, but it isn't ready for use in your organization yet. The cmdlet has been disabled for the tenant.

Examples

----------------------EXAMPLE-----------------------

Revoke-SPOUserSession -User user1@contoso.com

This example signs out user1 in the contoso tenancy from all devices.

Required Parameters

-User

Specifies a user name. For example, user1@contoso.com

Type:String
Position:0
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Online

Optional Parameters

-Confirm

Prompts you for confirmation before running the cmdlet.

Type:SwitchParameter
Aliases:cf
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Online
-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

Type:SwitchParameter
Aliases:wi
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Online

Inputs

None

Outputs

System.Object