How would I set the subtitle in a navigationbar in iOS26 via UIKit?
Asked on 2025-11-02
1 search
In iOS 26, you can set a subtitle in a UINavigationBar using the new Subtitle API provided by UINavigationItem. This allows you to render a subtitle below the title in the navigation bar. You can use attributed strings for fine-grained adjustments to both the title and subtitle. Here's a brief overview of how you might implement this:
-
Create an Attributed String: Use an attributed string to define the subtitle, allowing for customization of font, color, and other attributes.
-
Set the Subtitle: Assign the attributed string to the
subtitleproperty of yourUINavigationItem.
Here's a simple example in code:
let navigationItem = UINavigationItem(title: "Main Title")
let subtitleAttributes: [NSAttributedString.Key: Any] = [
.font: UIFont.systemFont(ofSize: 14),
.foregroundColor: UIColor.gray
]
let subtitle = NSAttributedString(string: "Subtitle", attributes: subtitleAttributes)
navigationItem.subtitle = subtitle
For more detailed information, you can refer to the session Build a UIKit app with the new design (08:54) from WWDC 2025, which covers the new design features in UIKit, including the navigation bar updates.

Build a UIKit app with the new design
Update your UIKit app to take full advantage of the new design system. We’ll dive into key changes to tab views, split views, bars, presentations, search, and controls, and show you how to use Liquid Glass in your custom UI. To get the most out of this video, we recommend first watching “Get to know the new design system” for general design guidance.

Code-along: Explore localization with Xcode
Learn how to localize your app into additional languages using Xcode. We’ll walk step-by-step through the process of creating a String Catalog, translating text, and exchanging files with external translators. You’ll learn best practices for providing necessary context to translators and how Xcode can help to provide this information automatically. For larger projects, we’ll also dive into techniques to manage complexity and streamline string management using type-safe Swift code.

What’s new in UIKit
Modernize your app with the latest APIs in UIKit, including enhanced menu bar support, automatic observation tracking, a new UI update method, and improvements to animations. We’ll also cover how you can include SwiftUI scenes in your UIKit app and explore SF Symbols, HDR color pickers, and more.
