AADSTS7000215: Invalid Client Secret Provided Error in Azure App Registration

While working on a Windows Forms application to manage folder-level permissions in SharePoint, I needed to fetch user names from Azure Active Directory.

To do this, we must register an app in Azure and then use our application’s Client ID, Tenant ID, and Client Secret. However, when I ran the application, I encountered an error related to authentication.

AADSTS7000215: Invalid client secret provided.
AADSTS7000215: Invalid Client Secret Provided

This error halted the process, which was attempting to connect to Microsoft Graph using the registered Azure AD application.

In this tutorial, I will show you how to fix the AADSTS7000215 error so you can successfully connect your SharePoint-integrated app to Azure AD.

AADSTS7000215: Invalid Client Secret Provided

In the Azure portal, when you register an application and create a client secret, Azure shows:

  • A Secret Value (which should be copied)
  • A Secret ID (used only for reference)

Authentication will fail if you copy and use the Secret ID in your code.

Now I will show you where you can find the Secret Value, then you will use it in your code:

  1. Go to Azure Portal -> Azure Active Directory -> App Registrations. Select your registered app. In my case, LibraryFolderSelectorApp is my application name.
AADSTS7000215 Invalid Client Secret Provided in Azure App Registration
  1. Then click Certificates & secrets, where you can see the secret value. If you didn’t copy the Secret Value earlier, delete the current one and create a new one. Copy the Secret Value immediately after it’s generated.
Client secret key is expired error - Azure

Use this Secret Value in your application code. This will fix the Invalid client secret provided error and allow your SharePoint-connected app to fetch user details from Azure AD.

You may like the following tutorials:

>
SPGUIDES.ACADEMY
LEARN. BUILD. TRANSFORM.
â–¶ Live FREE Webinar

Build an AI-Powered
Invoice Processing
App

Learn how to build an intelligent invoice processing solution using:

S SharePoint
â—† Power Apps
➤ Power Automate
✦ Copilot Studio
PDF INVOICE
→
AI
→
◆ ➤ S
From Invoice
to Insights
Invoice Processing ↑ Upload Invoice
INVOICE
TOTAL $1,950.00
Extracted Information
Vendor Name Contoso Ltd.
Invoice Number INV-1001
Invoice Date 09/05/2026
Due Date 09/25/2026
Line Items
Laptop 2 $1,600.00
Mouse 5 $150.00
✓ Save to SharePoint
â–£
DATE 22nd September 2026
â—·
TIME 10:00 AM EST 7:30 PM IST
⌛
DURATION 60 Minutes
🚀 Save Your Free Seat ›

Live Webinar

SharePoint Integration Power Apps Form With Repeating Table [Invoice Management System]

Learn how to build a real-world Invoice Management System using a SharePoint Integration Power Apps Form with a repeating table—supporting multiple invoice line items.

📅 2nd September 2026 – 10:00 AM EST | 7:30 PM IST

Build a High-Performance Project Management Site in SharePoint Online

User registration Power Apps canvas app

DOWNLOAD USER REGISTRATION POWER APPS CANVAS APP

Download a fully functional Power Apps Canvas App (with Power Automate): User Registration App

Power Platform Tutorial FREE PDF Download

FREE Power Platform Tutorial PDF

Download 135 Pages FREE PDF on Microsoft Power Platform Tutorial. Learn Now…