Grey bar on top of UIWebView in iOS 10
问题 When I drag a UIWebView from the Object Library in Xcode, I get a UIWebView with this dark grey bar at the top: What is that and how can I get rid of it? 回答1: You need put self.automaticallyAdjustsScrollViewInsets = NO; in ViewDidLoad The other choice is disable option Adjust Scroll View Insets in the .xib of your viewcontroller 回答2: That dark grey color is the background color set for the UIWebView. This will show if a webpage is smaller than the frame of the web view. You won't see it if