I understand that this question has been asked many, many times on SO. However, as Apple does best, with the release of iOS 11, they seem to ha
It's much simpler than that in Swift 5.
searchBar.barTintColor = .black searchBar.searchTextField.backgroundColor = .white