How can we disable "double tap to zoom" on Safari iOS 13+ mobile?
Sometimes it zooms, sometimes not. i feel it may only work on specific HTML-elements.
And i read that "double tap to zoom" should be disabled on iOS 13 by default and only pinch-zoom should work, but that's not the case.
Open the Settings app on the iPhone or iPad. Scroll down and choose the Safari browser from Settings. From Safari Settings, select the Page Zoom Safari option. Within the window, tap to select the Zooming level.
To turn off Zoom, double-tap the screen with three fingers or use accessibility shortcuts. On an iPhone with Display Zoom, you can see larger onscreen controls. Go to Settings > Display & Brightness > View, then turn on Display Zoom.
You can add the below meta tag to stop zooming on ios devices.
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1,user-scalable=0"/>
a css fix:
body{
touch-action: manipulation;
}
Hope is helps.
This works in Safari iOS 15
document.ondblclick = function(e) {
e.preventDefault();
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With