UISearchBar presented by UISearchController in table header view animates too far when active

Old question but I was able to solve this issue by setting

self.extendedLayoutIncludesOpaqueBars = YES;

on my view controller. I think is issue is caused by having an opaque navigation bar but setting hidesNavigationBarDuringPresentation to NO on your search controller, causing the search bar to incorrectly position itself when focused.

Leave a Comment