Conditional Access Problems

How to Control External OneDrive Sharing and Verification Codes

Emma BrownEmma Brown Nov 13, 2026 869 views

Question details

The user wants to control external OneDrive for Business sharing when recipients without Microsoft accounts receive eight-digit verification codes, and to make sure these links do not bypass Conditional Access or MFA.

Product
OneDrive for Business / SharePoint Online
Device & OS
not provided
Scenario
An organization needs to enforce Microsoft 365 sharing and access controls for external file recipients.
Observed behavior
External recipients use one-time verification codes to open shared files, so standard Conditional Access and multifactor authentication requirements may not apply.
Before you start

Sign in to the Microsoft 365 admin center with an account that has Global admin or SharePoint admin permissions, and verify the current external sharing settings for SharePoint and OneDrive before changing them.

Solution 1Recommended

Set OneDrive and SharePoint external sharing to only people in your organization

Use this when external sharing is not required and you need to block verification-code links across the tenant.

Microsoft does not provide a tenant setting that requires every external recipient to create a Microsoft account. Disabling external sharing or setting sharing to Only people in your organization is the direct way to prevent one-time passcode links from bypassing Conditional Access and MFA.

1
Open the SharePoint admin center

Sign in to the Microsoft 365 admin center at admin.microsoft.com, then select Admin centers > SharePoint.

2
Open sharing policies

In the SharePoint admin center, expand Policies and click Sharing.

3
Restrict external sharing for SharePoint and OneDrive

Under External sharing, move both the SharePoint and OneDrive sliders to Only people in your organization.

4
Save the policy

Click Save at the bottom of the page. External recipients will no longer be able to access shared files through verification-code links.

No Microsoft account requirement: Microsoft does not offer a setting to force external recipients to create Microsoft accounts. To block verification-code sharing, you must disable external sharing or restrict it to internal users only.
Free Microsoft Office alternative

Use WPS Office to Control Document Sharing Without OneDrive Verification-Code Links

WPS Office is a free, lightweight Microsoft Office alternative with WPS Cloud sharing and full support for Word, Excel, and PowerPoint files, so you can share documents through controlled WPS Cloud links instead of OneDrive one-time passcode links.

  1. 1. Download WPS Office: Click Download WPS Office Free and install the suite on Windows, macOS, Android, or iOS.
  2. 2. Open your Microsoft Office files: Launch WPS Office and open .docx, .xlsx, or .pptx files directly from your local or cloud storage.
  3. 3. Use WPS Cloud for sharing: Save the file to WPS Cloud and share it with specific team members from within WPS Office.
Controlled WPS Cloud sharing that avoids anonymous OneDrive verification-code linksOpens and saves Microsoft Word, Excel, and PowerPoint formats without conversion issuesFamiliar Office-style ribbon interface for easy migrationLightweight, free download with no subscription required for core editing features
microsoft office alternative - wps office

Frequently Asked Questions

Why don’t OneDrive verification-code links follow Conditional Access policies?

Verification-code recipients are not signed in to a Microsoft 365 identity, so Conditional Access policies are not evaluated. Conditional Access applies to authenticated users and guest accounts.

Can I force external recipients to create a Microsoft account before opening shared files?

No. Microsoft does not expose a setting that requires external recipients to create a Microsoft account. The closest control is to disable external sharing or restrict sharing to internal users.

What happens to existing external sharing links when I set sharing to Only people in your organization?

External recipients lose access to those shared files. Internal users and links scoped to people in your organization continue to work according to the new tenant policy.

How do I check my current OneDrive and SharePoint external sharing settings?

Open the SharePoint admin center from the Microsoft 365 admin center, expand Policies, click Sharing, and review the SharePoint and OneDrive external sharing sliders.

Does WPS Office support files created in OneDrive for Business?

Yes. WPS Office opens and saves .docx, .xlsx, and .pptx files, and includes WPS Cloud for sharing with specific users.