IOS – save an HTML file to the iPhone and open in Safari

htmliosiphonesafari

Does anyone know if its possible to save an HTML file to your iphone and then open it with Safari so that you can then favourite it and have it appear on the launcher as an icon?

Best Answer

Once the page is opened on your iPhone all you have to do is tap the Sharing icon, middle icon on bottom, and select 'Add to Home Screen'

If you want to load an html file that you've created on you Mac to your iPhone you'll need to do the following. From System Prefs > Sharing > Enable Web Sharing. Place the html file in your ~/Sites folder. Go the the URL listed in the Web Sharing panel from your iPhone, while on the home network, and open the html file. It will load in Mobile Safari.

If you want this to stay on your iPhone you'll need to have the page written in html5 and have a properly setup CACHE MANIFEST. This includes the appropriate tag in the html file and have the proper manifest file. Then you can follow the first step and add it to your home screen and always have it on your iPhone.