How to Fix OneDrive Login Prompts for Anyone-Shared Files
Question details
External users are being asked to sign in to a Microsoft account when attempting to open specific files located inside a folder shared with an 'Anyone' link.

- Product
- Microsoft OneDrive
- Device & OS
- not provided
- Scenario
- A user shares a OneDrive folder publicly on a website using an 'Anyone with the link' setting, expecting external visitors to view the contents without needing an account.
- Observed behavior
- While the main folder opens correctly without authentication, clicking on individual files (such as PDFs) opens a new tab and prompts external users for a Microsoft account login.
Ensure you are signed into the Microsoft account that owns the shared folder and that you have the necessary administrative privileges to manage file-level sharing permissions.
Verify and Adjust Individual File Permissions
Check if the specific file has inherited the folder's public permissions or if it has more restrictive settings applied to it.
Even if a parent folder is shared with an 'Anyone' link, individual files inside that folder can sometimes retain unique, restrictive permissions. This mismatch is the most common reason external users see a sign-in prompt.
Open OneDrive or SharePoint and navigate to the folder containing the file that is prompting for a login.
Right-click the specific file (e.g., the PDF) and select 'Manage Access' from the context menu.
Look at the current links and permissions assigned directly to the file. If it lacks an 'Anyone with the link' setting, generate a new sharing link for the file specifically configured for 'Anyone'.

Test File Links in a Private Browsing Window
Use an incognito or private browsing session to accurately simulate the experience of an external, non-authenticated user.
Share and Collaborate Seamlessly with WPS Office
If you are tired of dealing with complex permission settings, inherited access issues, and unexpected login prompts in Microsoft OneDrive, try WPS Office. It provides a lightweight, entirely free Office suite with built-in cloud storage that makes public file sharing straightforward and hassle-free.
- 1. Open your file in WPS Office: Launch WPS Office and open the document you wish to share publicly.
- 2. Create a sharing link: Click the 'Share' button in the top right corner and select 'Create Link'.
- 3. Set permissions to Anyone: Choose 'Anyone with the link can view' to ensure external users will not be prompted for a login.

Frequently Asked Questions
Why does a folder open without a login, but a file inside it requires one?
This happens when the individual file does not properly inherit the 'Anyone' permission from the parent folder. The file may have had unique, restrictive permissions applied to it before it was moved into the shared folder.
How can I guarantee external users never need to log in to view my files?
You must ensure that the sharing link generated is explicitly set to 'Anyone with the link can view'. Always test the final link in an incognito or private browser window while fully signed out to verify the public access works.
Does it matter if the file is embedded on a public website?
Yes. If you embed a OneDrive or SharePoint file on a website, you must use an 'Anyone' embed link. Standard sharing links might try to authenticate the session, causing embedded frames to show a login screen or an error.




