Others

Fix AzCopy OAuth Token Error When Copying to Azure Blob Storage

Steve KSteve K Nov 13, 2026 869 views

Question details

The user needs to resolve the AzCopy 10 error “no SAS or OAuth token is present” when copying files from a network share to a private Azure Blob Storage destination that requires authentication.

Product
AzCopy 10 and Azure Blob Storage
Device & OS
not provided
Scenario
Copying files from a network share to a private Azure Blob Storage container using AzCopy 10.
Observed behavior
AzCopy reports that no SAS or OAuth token is present and does not complete the copy to the private destination.
Before you start

Confirm whether the destination Azure Blob container or storage account is set to private. Have your Azure tenant ID or a valid SAS token ready before running AzCopy.

Solution 1Recommended

Sign in with Azure AD and assign Storage Blob Data Contributor to the destination storage account

Use this solution when the destination is private and you want password-less authentication through the Azure AD identity running AzCopy.

Private Azure Storage does not allow anonymous access. AzCopy must present either an Azure AD OAuth token or a SAS token, so signing in with the correct tenant is the first fix.

1
Open a command prompt or terminal

Open Command Prompt, PowerShell, or your terminal in the environment where AzCopy 10 is installed.

2
Run azcopy login

Type azcopy login and press Enter. If your account belongs to multiple tenants, run azcopy login --tenant-id <tenant-id> to avoid selecting the wrong directory.

3
Assign the storage data role in Azure portal

In the Azure portal, go to the Storage account or Blob container, select Access control (IAM) > Add role assignment, choose Storage Blob Data Contributor, and assign it to the signed-in user or service principal.

4
Run the copy command again

Rerun the AzCopy command, for example: azcopy copy "\\server\share\file" "https://<account>.blob.core.windows.net/<container>/<file>" --recursive.

Sign in with Azure AD and assign Storage Blob Data Contributor to the destination storage account
Authentication fixed: The copy now obtains an OAuth token from Azure AD and can access the private container.
Free Microsoft Office alternative

Use WPS Office as a Free Office Alternative for Files Copied to Azure Blob Storage

AzCopy authentication must be resolved in Azure, but WPS Office is a free lightweight Office suite for the Word, Excel, and PowerPoint files you copy to Azure Blob Storage. It supports Microsoft Office files, keeps a familiar interface, and works well after your Azure data transfer.

  1. 1. Download WPS Office: Go to the WPS Office website and download the free installer for Windows, macOS, Linux, Android, or iOS.
  2. 2. Open files copied to Azure Blob Storage: After the AzCopy transfer succeeds, open the downloaded Word, Excel, or PowerPoint files in WPS Office.
  3. 3. Edit and save in Office formats: Edit documents and save them as .docx, .xlsx, or .pptx to preserve Microsoft Office compatibility.
Opens and edits .docx, .xlsx, and .pptx files that you copy to Azure Blob Storage.Free and lightweight Office alternative without Microsoft 365 licensing.Maintains Microsoft Office format compatibility for seamless file exchange.Familiar ribbon-style interface makes migration easy.Focuses on document work while you manage Azure Blob authentication in AzCopy.
microsoft office alternative - wps office

Frequently Asked Questions

Why does AzCopy 10 say “no SAS or OAuth token is present”?

Because the destination Azure Blob container is private and AzCopy has not obtained an Azure AD OAuth token or SAS token. Run azcopy login or append a valid SAS token to the destination URL.

How do I log in to Azure AD with AzCopy?

Run azcopy login in the terminal, complete the browser authentication, and if necessary specify azcopy login --tenant-id <tenant-id> to select the correct tenant.

Can I copy to a private Azure Blob Storage account anonymously?

No. Private containers require authentication. Use Azure AD role-based access or a SAS token.

How do I assign Storage Blob Data Contributor to an Azure AD user?

In the Azure portal, open the storage account or container, go to Access control (IAM), click Add role assignment, select Storage Blob Data Contributor, and select the user or service principal.

How do I append a SAS token to an AzCopy destination URL?

Create the SAS in the storage account's Shared access signature page, copy the query string, and append it to the blob or container URL with ? before the token.