Last active
September 26, 2025 09:21
-
-
Save LukasCZ/9b8f74bf13e1c24244a6951490c4bf50 to your computer and use it in GitHub Desktop.
Fix for broken layout of large navigation titles when building with Xcode 26 and running on iOS 18.
Author
Another solution is to set UINavigationBar.appearance().layoutMargins.left = 16 in didFinishLaunchingWithOptions of AppDelegate for iOS below 26.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Ever since Xcode 16 and iOS 26 SDK beta 1, there has been this issue of missing left margin of large navigation titles on iOS 18:

This code fixes it.
Usage
Call
LargeNavTitlesOniOS18Fixer.shared.register(self.navigationController?.navigationBar)in-viewDidLoad()and-viewDidAppear()methods of your view controllers that are used as the root in a UINavigationController stack.