You can make a difference in the Apple Support Community!

When you sign up with your Apple Account, you can provide valuable feedback to other community members by upvoting helpful replies and User Tips.

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

How can I open local HTML files on my iPhone 15 Pro using Safari?

Is it possible to store the HTML files of a website on my iPhone, and then view the site locally using (for example) Safari? It seems as though the inter-page links aren't working correctly after copying the files.


iPhone 15 Pro

iOS 17.4.1


[Re-Titled by Moderator]


iPhone 15 Pro

Posted on Mar 27, 2024 7:51 AM

Reply
Question marked as Top-ranking reply

Posted on Mar 27, 2024 5:23 PM

Mark92630 wrote:

Is it possible to store the HTML files of a website on my iPhone, and then view the site locally using (for example) Safari? It seems as though the inter-page links aren't working correctly after copying the files.

Sort of. You can indeed save HTML files to the Files app and view them later- the correct styling should even apply as long as any relevant CSS is embedded in the document. However, the saved document probably won't link to other HTML pages correctly because the file paths are still trying to find the document in the context of the web server.


Instead, you can save the websites to your Reading List. To enable offline reading of items in the list, go to Settings > Safari, then turn on Automatically Save Offline (below Reading List).


Save webpages to read later in Safari on iPhone - Apple Support

Similar questions

3 replies
Question marked as Top-ranking reply

Mar 27, 2024 5:23 PM in response to Mark92630

Mark92630 wrote:

Is it possible to store the HTML files of a website on my iPhone, and then view the site locally using (for example) Safari? It seems as though the inter-page links aren't working correctly after copying the files.

Sort of. You can indeed save HTML files to the Files app and view them later- the correct styling should even apply as long as any relevant CSS is embedded in the document. However, the saved document probably won't link to other HTML pages correctly because the file paths are still trying to find the document in the context of the web server.


Instead, you can save the websites to your Reading List. To enable offline reading of items in the list, go to Settings > Safari, then turn on Automatically Save Offline (below Reading List).


Save webpages to read later in Safari on iPhone - Apple Support

Mar 30, 2024 8:46 AM in response to Mark92630

Mark92630 wrote:

That works. What it doesn't do is allow me to preserve a local copy of multiple pages (for example, a table of contents page and all of the pages linked from it) with a single command. Instead, I have to traverse the entire set of pages manually, saving each one to the Reading List.

There should be an app for that. ;-)

Ah, gotcha- what you need is a website scraper. Unfortunately those aren't very widespread, especially for a mobile device. I have used this tool, HTTrack, before, but it's only for Windows computers. As far as I know, there's no web scraping apps that will actually crawl, then save, the entire website on a mobile device. If you have a Windows PC however, you could use that to download the website, then share it with your iPhone and save it in Files for later reading.


Maybe let Apple know if you'd like - Feedback/Suggestions - Safari on iOS - Apple

How can I open local HTML files on my iPhone 15 Pro using Safari?

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.