Use specific <meta> and <link> tags to optimize your web application for iOS devices. This includes setting up Smart App Banners, disabling automatic phone number detection, defining launch icons, and configuring standalone mode.
Note: For Progressive Web Apps (PWAs), it is recommended to use a Web App Manifest (<link rel="manifest">) for properties like apple-touch-icon and apple-mobile-web-app-title. The meta tags below serve as useful fallbacks for older iOS versions.
<!-- Smart App Banner -->
<meta name="apple-itunes-app" content="app-id=APP_ID,affiliate-data=AFFILIATE_ID,app-argument=SOME_TEXT">
<!-- Disable automatic detection and formatting of possible phone numbers -->
<meta name="format-detection" content="telephone=no">
<!-- Launch Icon (180x180px or larger) -->
<link rel="apple-touch-icon" href="/path/to/apple-touch-icon.png">
<!-- Launch Screen Image -->
<link rel="apple-touch-startup-image" href="/path/to/launch.png">
<!-- Launch Icon Title -->
<meta name="apple-mobile-web-app-title" content="App Title">
<!-- Enable standalone (full-screen) mode -->
<meta name="mobile-web-app-capable" content="yes">
<!-- Status bar appearance (has no effect unless standalone mode is enabled) -->
<meta name="apple-mobile-web-app-status-bar-style" content="black">
<!-- Viewport fit for notched phones (iPhone X and later); add viewport-fit=cover to your existing viewport meta tag -->
<meta name="viewport" content="width=device-width, initial-scale=1, viewport-fit=cover">
<!-- iOS app deep linking -->
<meta name="apple-itunes-app" content="app-id=APP_ID, app-argument=http/url-sample.com">
<link rel="alternate" href="ios-app://APP_ID/http/url-sample.com">