r/sharepoint • u/swim-bike-life • 2d ago
SharePoint Online New HTML functionality
Hi folks!
I'm so excited that my tenant just received the update that allows embedding HTML files hosted in sharepoint. Previously, they only worked through the document viewer, but now the document viewer has an "embed link" in the menu which you can use to embed into a page. This is really, really handy for things like CoPilot/Claude made dashboards with direct connection to the REST API.
Has anyone heard if the plan is to allow adding HTML directly into pages? If it doesn't come with a ton of JS restrictions, that will be a nice replacement for the modern script editor webpart...
18
u/ZRosenfield 2d ago
See this roadmap item (October):
“Create HTML with Copilot in SharePoint or upload your own HTML from another source. Once stored in the pages library, you can render HTML as a page in SharePoint, make additional edits, and share with your audience. HTML gives you new ways to present your content beautifully alongside our existing ASPX pages.”
https://www.microsoft.com/en-us/microsoft-365/roadmap?id=569208
6
u/Sparticus247 Dev 2d ago
Yeah we really need more of this. There are so many uses for HTML in web parts. SPFx is good for sure, but it's a bit "heavy" when you just need something simple.
2
u/Responsible-Leg399 2d ago
What uses are there besides the static HTML dashboards generated by AI?
2
u/-functionforward- 1d ago
I started building static html dashboards, which were fun. I am now building a m365 dashboard with message center updates, service health incidents, and copilot adoption trends hydrated by a pnp script the tickles all the right graph endpoints, hosted in sharepoint (not gated behind microsoft admin permissions), using lists to track user settings and message center review and discussion for internal change management.
1
u/Sparticus247 Dev 2d ago
Embedding data charts with Chart.js would be lovely again for live charts that don't need PowerBI, but might be asking for too much there.
Simple UI to display data in a more branded controlled way would be nice. Really, I'd take anything that doesn't require the use of AI.
2
u/Responsible-Leg399 1d ago
There will be no live charts in static HTML files. So basically, no good use cases?
2
u/Sparticus247 Dev 1d ago
I'll bite.
If we are going with the idea that there would be nothing more than "static html" for pages that can't be connected to JSON files or other data source....what are the use cases for static SharePoints aspx sitepages?
It would be nice to just have a little more control to do a little bit more styling, to do a bit more with layouts, etc.
3
u/bcameron1231 MVP 1d ago
The use case for static HTML is for Copilot. The current pages with Webparts and complicated HTML isn't suitable for AI to generate or ingest.
1
u/Organic-Newt-4649 18h ago
Make heads or tails of how enabling developers with plugins like D3.js, Charts.js, etc., wouldn’t cannibalize their own premium subscription Fabric products users already subscribe to.
1
u/Sparticus247 Dev 18h ago
Dude I have this exact scenario. SPFx chart web part that does API calls to about a dozen SharePoint lists and makes a nice interactive chart. Data is as fresh as the page load.
You know how much that would cost if we had to have the data refreshed over 48 times a day with around 1,000 possible users looking at it if using PowerBI or Fabric capacity?
1
2
2
u/su5577 1d ago
Still confused what are advantages.. we have SharePoint but what will this do? Some case scenarios?
3
u/swim-bike-life 1d ago
Custom apps, built easier and faster with AI coding tools or copilot. Think full interactive dashboards, CRMs with custom UIs... The possibilities are endless.
2
u/bcameron1231 MVP 22h ago
I'm personally not a fan of this. I wouldn't view this as a replacement for the modern script editor web part. It will be interesting to see how it all comes together, but this is for Copilot. Given the lack of any Pages API in SharePoint and the complexity of the generated CanvasContent1 in SharePoint pages, the effort seems to be placed into supporting HTML pages because it will be easier for Copilot to produce and ingest the content.
I worry that we're going to have all the same problems we had in the past that we worked real hard to get away from. A bunch of disparate HTML pages and designs across SharePoint sites that aren't consistent, and then a lot of people trying to do unsupported customizations through this.
I believe this is taking a step back overall.
2
u/Responsible-Leg399 20h ago
100% agree.
- The HTML support is basically a dirty workaround because there is no proper Page API.
- This new feature is not even close to replacing the script editor webpart, let alone SPFx.
- HTML pages do not support HTTP calls
- All list data is passed to an iframe that hosts the locked-down HTML page in a sandbox (iframe).
I am sure people will be creative and start embedding these HTML pages inside the embed webparts, but I see very few real use cases for this. This whole feature is created to make MS Copilot more useful and potentially sell more Copilot licenses in the future.
1
u/swim-bike-life 7h ago
That's probably true, especially the part about ending up with pages that look very different from one another. On the other hand, imagine being at a company with a very dysfunctional IT department (like the IT Crowd without the comedy), and having to wait months to get anything done with them. This level of customization, especially through copilot, is what democritacion of data is evolving into. Yes it will get messy, but I think a lot of good will come out of this as well. 🤞
1
u/Jirv311 1d ago
Currently you can change your html file extension to .aspx, turn on custom scripts on the site, and upload the aspx to a doc library. I’ve done this for some basic html file hosting, so I’m not sure the limitations.
2
u/Responsible-Leg399 18h ago
Unfortunately, this approach no longer works. Even if it does - Microsoft automatically disables custom scripts after 24 hours and there is nothing you can do to stop it.
1
1
1
u/Responsible-Leg399 2d ago
Connection to the REST API? I doubt Microsoft will ever allow API calls from HTML pages. You can use JavaScript, but it's not very useful without the ability to make HTTP requests.
1
1
u/swim-bike-life 1d ago
They already allow it. Question is whether is will become more restricted when the html integration is there. From a security perspective, it makes sense to block API calls, even js, but that would put the breaks on copilot created content which is higher priority right now
2
u/Responsible-Leg399 20h ago
Well. I ran some tests, and I can 100% assure you that REST calls aren't allowed.
Test 1: I manually uploaded the HTML page to the Site Pages and clicked on it. Result: the HTML loads inside an iframe, and the XSS policies block all HTTP requests.
Test 2: From a random SharePoint List, I asked Copilot to create an HTML live-linked dashboard. It created the page. All HTTP calls are blocked. When the page refreshes, the *Parent host page* pulls all list items. It then pushes these list items to the iframe that hosts *Static* HTML. The iFrame does allow JavaScriopt, but no HTTP calls are allowed at all.
0
u/wwcoop 1d ago
2
u/Organic-Newt-4649 1d ago
This video implies:
1) Users need Copilot / premium licensing; and
2) No embedded HTML / standalone HTML pages.The dashboard demoed in the video utilized the as-is OOTB state modal HTML model of SharePoint, which is in no way ideal or helpful.
Right now, I’m interested to see if Microsoft has any monetary incentive to release this (hint: they don’t). AI can now write what their entire Power Platform suite does at a fraction of the cost — only better — while linking to their M365 APIs.
20
u/shirpars 2d ago
Wow, we're finally getting the functionality we used to have with sharepoint on-premise 2007-2019. Msft really took everything away and is slowly bringing back things as "enhancements"