Remove-BitsTransfer is accessible with the help of BitsTransfer module. To configure BitsTransfer, go through this link.


Cancels a BITS transfer job.


The Remove-BitsTransfer cmdlet cancels a Background Intelligent Transfer Service (BITS) transfer job. It deletes the underlying transfer job, removes any temporary files from the client, and deletes the associated BitsJob object.

When the Remove-BitsTransfer cmdlet cancels a transfer job, it deletes all the transfers. Consider a scenario is which you are transferring three files. One file is completely transferred, one file is pending, and one file is currently being transferred. In this scenario, Remove-BitsTransfer cancels the whole transfer and deletes the underlying files. Any files that were already transferred are not available after you use the Remove-BitsTransfer cmdlet to cancel the transfer job. Optionally, you can use the Complete-BitsTransfer cmdlet to commit any files that are completely downloaded and to cancel the pending and current transfers. The transferred file is not be deleted and is available.



Specifies an array of BITS transfer jobs to cancel. You can pipe a value to this parameter from other cmdlets that return BitsJob objects, such as the Get-BitsTransfer cmdlet.

Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False


Prompts you for confirmation before running the cmdlet.

Default value:False
Accept pipeline input:False
Accept wildcard characters:False


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

Default value:False
Accept pipeline input:False
Accept wildcard characters:False


Remove-BitsTransfer [-BitsJob] <BitsJob[]> [-WhatIf] [-Confirm] [<CommonParameters>]

After a job is removed or completed, any job objects that were previously cached in variables or in scripts are no longer valid.

—————Example 1—————
Cancel all BITS transfer jobs owned by the current user
PS C:>Get-BitsTransfer | Remove-BitsTransfer
This command cancels all the BITS transfer jobs that are owned by the current user.
The output of the Get-BitsTransfer cmdlet is piped to the Remove-BitsTransfer cmdlet. The output is a set of BitsJob objects.

—————Example 2—————
Cancel all BITS transfer jobs on the computer
C:\PS>$Bits = Get-BitsTransfer -AllUsers
PS C:> Remove-BitsTransfer -BitsJob $Bits
This command cancels all the BITS transfer jobs on the computer.
The first command gets all the BitsJob objects on the computer and then stores them in the $Bits variable.
The second command uses the BitsJob parameter to pass the BitsJob objects that are stored in the $Bits variable to the Remove-BitsTransfer cmdlet.

You can check the Version, CommandType and Source of this cmdlet by giving below command.

Get-Command Remove-BitsTransfer

Get-Command Remove-BitsTransfer powershell script command cmdlet

You can also read about

  • Add-BitsFile
  • Complete-BitsTransfer
  • Get-BitsTransfer
  • Resume-BitsTransfer
  • Set-BitsTransfer
  • Start-BitsTransfer
  • Suspend-BitsTransfer

To know more PowerShell cmdlets(Commands) on BitsTransfer click here

Click on this Link for an Single place where you get all the PowerShell cmdlet sorted based on the modules.

You can also refer other blogs on PowerShell at link

You can also refer other blogs on Microsoft at link

And also if you required any technology you want to learn, let us know below we will publish them in our site

Like our page in Facebook and follow us for New technical information.

References are taken from Microsoft

Leave a Reply

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