Permission & Access Issues

How to Read SharePoint Files in Android with Microsoft Graph (Fix 403 Error)

Steve KSteve K Oct 21, 2026 870 views

Question details

The user needs to authenticate an Android application with Microsoft Graph to download and read SharePoint files without triggering a 403 Forbidden error.

How to Read SharePoint Files in Android Using Microsoft Graph
Product
Microsoft Graph API
Device & OS
Android
Scenario
Developing an Android application that uses the Microsoft Graph API to access and read documents stored on a SharePoint site.
Observed behavior
The Android application encounters a 403 Forbidden response when making requests to the SharePoint file endpoints, indicating an authentication or permissions failure.
Before you start

Ensure you have administrator access to your Microsoft Entra ID (formerly Azure AD) tenant to configure application registrations and grant necessary API permissions.

Solution 1Recommended

Register App and Authenticate via Microsoft Entra ID

Properly register the Android application to obtain an OAuth 2.0 access token via MSAL, ensuring the correct permissions are granted to bypass the 403 error.

A 403 Forbidden error when accessing SharePoint via Microsoft Graph usually means the access token lacks the required scopes (permissions). To fix this, your app must be registered in Microsoft Entra ID and configured to request explicit file access permissions.

1
Register the Android App

Log in to the Microsoft Entra admin center, navigate to 'App registrations', and create a new registration for your Android application.

2
Configure Android Platform Settings

Under 'Authentication', add a platform for Android. You will need to provide your app's Package Name and the Signature Hash generated from your keystore.

3
Add Microsoft Graph Permissions

Navigate to 'API permissions', click 'Add a permission', select 'Microsoft Graph', and choose 'Delegated permissions'. Search for and add permissions such as 'Files.Read.All' or 'Sites.Read.All'.

4
Grant Admin Consent

If you are requesting permissions that require administrative approval, click the 'Grant admin consent for [Tenant]' button in the API permissions screen to authorize the app globally.

5
Implement MSAL in Android

Integrate the Microsoft Authentication Library (MSAL) into your Android project. Use it to acquire an access token interactively or silently, and include this token in the 'Authorization: Bearer' header of your Microsoft Graph HTTP requests.

Register App and Authenticate via Microsoft Entra ID
Verify Token Claims: During debugging, you can decode your JWT access token to verify that the 'scp' (scopes) or 'roles' claims explicitly contain the SharePoint permissions you requested.
Free Microsoft Office alternative

Access Cloud Documents Easily with WPS Office for Android

If you are looking for a reliable way to view and manage SharePoint or OneDrive documents on your Android device without building custom apps, WPS Office is an excellent, free alternative to Microsoft Office. It offers powerful cloud integrations and full format compatibility.

  1. 1. Download WPS Office: Install the free WPS Office app from the Google Play Store on your Android device.
  2. 2. Connect Your Cloud Account: Open WPS Office, navigate to the Cloud tab, and select OneDrive/SharePoint to log in with your Microsoft credentials.
  3. 3. Read and Edit Documents: Tap on any document stored in your cloud to instantly read, edit, or share it directly from your phone.
Seamlessly connects to third-party cloud services including OneDrive, Google Drive, and Dropbox.Complete compatibility with Microsoft Office formats like .docx, .xlsx, and .pptx.Lightweight Android app that saves device storage and memory.Familiar, easy-to-use mobile interface for reading and editing documents on the go.
microsoft office alternative - wps office

Frequently Asked Questions

Why do I get a 403 Forbidden error even after obtaining a Graph API token?

A 403 Forbidden error typically occurs because the access token does not contain the specific permissions required for the SharePoint endpoint you are calling. Verify that 'Files.Read.All' or 'Sites.Read.All' was granted and that admin consent was provided in Microsoft Entra ID.

Can I use a personal Microsoft account to read SharePoint files via Graph API?

SharePoint access through Microsoft Graph generally requires a work or school account authenticated via Microsoft Entra ID. Personal accounts are typically restricted to accessing personal OneDrive files.

Where can I get implementation help for MSAL on Android?

You can find comprehensive documentation and Android code samples for MSAL on GitHub, or request tailored developer support within the official Microsoft Q&A community.