I'm trying to figure out a very vexing bug (which might well be a mobile Safari issue) where opening a URL from an app is causing the page to load with a large negative scroll value and only the Smart Banner appearing.

In the example below, window.scrollY = -324. This is on iOS 8.1.2, both iPad and iPhones.

iPad Smart Banner initial scroll problem

The page does not have any scrolling-related javascript executed on page load. Everything appears as expected in the DOM, but when Smart Banner is enabled, this scroll issue happens somewhat sporadically. (It appears to happen most consistently

The issue resolves itself after any touch or rotate event, suggesting the browser knows that window.scrollY should be 0.

Has anyone dealt with a similar issue?

1 Answer 1


This appears to be a bug in mobile Safari. I was able to replicate this bug using a demo iOS app. Full details are here: https://github.com/than/Mobile-Safari-Smart-Banner-Viewport-Bug

Video of the bug in action: https://www.youtube.com/watch?v=IEILZ9uyH4g

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .