There will be times where you want to give an administrator or another user access to another user's mailbox. This blog post will describe how to add and remove access permissions on one or more mailboxes with PowerShell.

Add access permissions to a mailbox

Add-MailboxPermission -Identity -User -AccessRights FullAccess -InheritanceType All

Remove access permissions from a mailbox
When you want to remove the permissions again, just replace Add-MailboxPermission with Remove-MailboxPermission.
Remove-MailboxPermission -Identity -User -AccessRights FullAccess -InheritanceType All

Add access permissions to all mailboxes
If you want to give access permissions to all mailboxes on Office 365, use the PowerShell cmdlet below.
Get-Mailbox -ResultSize unlimited -Filter {RecipientTypeDetails -eq 'UserMailbox'} | Add-Mailboxpermission -User -AccessRights fullaccess -InheritanceType all

List mailbox permissions
If you want to see permissions of a mailbox, use this cmdlet.
Get-MailboxPermission -Identity | Select User, AccessRights, Deny