I am trying to embed a static SharePoint page (.aspx file) using the Embed webpart on a SharePoint online site. The file is added to the Share Documents directory of the same site.
The end goal is to host a static website inside an iFrame on the SharePoint site. This static website will have some HTML pages (with the extension changed to .aspx), images, CSS, and JS. I have achieved this goal in my previous organization on a Classic SharePoint site using the Page Viewer webpart.
However, my current organization is using modern SharePoint site and I want to achieve the same goal on the modern site. After referring to a few of the articles over the internet, I saw that the custom scripts need to be enabled for the site where I want to embed the aspx files. On my request the IT team has enabled the custom scripts, but still no luck in displaying the pages. The site is still showing the "File not found" error.