Fix Blank Pages When Opening HTML Links in SharePoint
Question details
Users need to resolve an issue where clicking links inside an uploaded HTML file stored on SharePoint opens a completely blank page instead of the expected destination.

- Product
- SharePoint
- Device & OS
- not provided
- Scenario
- Accessing and navigating HTML files stored in a SharePoint document library, specifically when viewing them in presentation mode in a web browser.
- Observed behavior
- Instead of properly rendering the destination URL or executing the HTML link's action, the browser opens a blank page.
Contact your SharePoint or global IT administrator, as resolving this issue usually requires administrative privileges to adjust site-level script and security settings.
Enable Custom Scripts in SharePoint Admin Center
Verify if SharePoint is blocking custom scripts, which prevents HTML files from executing scripts and links properly in the browser.
By default, SharePoint online blocks custom scripts on self-service created sites for security reasons. This restriction strips out or blocks HTML tags and scripts, causing HTML pages to load blank or improperly. An administrator must allow custom scripts for the specific site.
Sign in to the Microsoft 365 admin center as a Global or SharePoint Administrator, and navigate to the SharePoint admin center.
Click on 'Settings' in the left-hand navigation pane, then select the classic settings page link at the bottom.
Scroll down to the 'Custom Script' section. Select 'Allow users to run custom script on personal sites' and 'Allow users to run custom script on self-service created sites'. Click 'OK' to save.

Convert HTML Files to ASPX Format
If enabling custom scripts is not an option due to organizational security policies, convert the HTML file into a SharePoint-native ASPX page.
Manage and View Documents Seamlessly with WPS Office
If SharePoint's strict security settings make web-based document and HTML rendering difficult, consider managing your essential documents locally and collaboratively using WPS Office. It provides a highly compatible environment for opening, editing, and sharing standard Office files without relying on browser-based viewers.
- 1. Download and Install: Visit the official WPS Office website and download the free version for your operating system.
- 2. Open Your Documents Locally: Instead of relying on web viewers, download your presentation files and open them directly in WPS Office for flawless formatting.
- 3. Export as PDF for Web Sharing: If you need to share presentations securely online without HTML link errors, use WPS Office to export your document as a PDF.

Frequently Asked Questions
Why does SharePoint show a blank page for my HTML file?
SharePoint restricts standard HTML file execution to protect users from malicious code. If the 'Custom Script' setting is disabled, SharePoint strips necessary code from the HTML file, resulting in a blank page when viewed in the browser.
Can I view my HTML files in SharePoint without administrator rights?
If you cannot contact an administrator to change site settings, your best workaround is to download the HTML file from the SharePoint library to your local computer and open it directly in your preferred web browser.
Is it safe to enable custom scripts in SharePoint?
Enabling custom scripts allows users to inject HTML and JavaScript into sites. While it fixes HTML rendering issues, it does introduce potential security risks. Administrators should evaluate their organization's security policies before enabling this feature globally.
Why use ASPX instead of HTML in SharePoint?
ASPX is natively recognized and processed by Microsoft IIS and SharePoint servers. Converting a standard HTML file to an ASPX page often allows the server to correctly render the content and links without being blocked by basic HTML security filters.




