On macOS 26, how do you support the Preferred Text Size value as defined in the Accessibility Settings?
Historically, "Dynamic Type" has not been available on macOS. However, the user has some control over text size through the Accessibility Settings.
On macOS 26, a small subset of applications are honouring changes to that value include Finder, Mail, and sidebars in many applications.
Dynamic sizing in table views has been available on macOS for awhile. But Mail.app, in particular, is also adjusting the font sizes used in the message's body pane while the Finder is adjusting font sizes used for Desktop icons.
I can't find an NSNotification that is fired when the user adjusts the Accessibility Text Size slider, nor can I find an API to read the current value.
NSFont.preferredFont(forTextStyle:options:) looks promising but the fonts returned do not appear to take the user's Accessibility setting into account. (Nor do they update dynamically.)
SwiftUI's Text("Apple").font(.body) performs similarly to NSFont in that it does respect the style, but it does not honour dynamic sizing.
NSFontDescriptor has a bunch of interesting methods, but none that seem to apply to Accessibility Text Size.
Given an AppKit label:
let label = NSTextField(labelWithString: "AppKit")
label.font = NSFont.preferredFont(forTextStyle: .body)
Or a SwiftUI label:
Text("SwiftUI").font(.body)
How do I make either of them responsive to the user's Text Size setting under Accessibility?
Note this is on macOS 26 / Xcode 26. I realize there have been some previous forum posts related to this issue but hoping that things might have improved since then.
Dynamic Type is a system-level feature for iOS, iPadOS, tvOS, visionOS, and watchOS.
However, all platforms support dynamic optical sizes when using system fonts.
With dynamic optical sizes, you don’t need to use discrete optical sizes unless you’re working with a design tool that doesn’t support all the features of the variable font format.
These sizes, like .title, caption, etc.. are discussed in Adopt the new look of macOS
When using system fonts through APIs like preferredFont(forTextStyle:options:), the dynamic optical sizing behavior is automatic. Learn more about this here: The details of UI typography.
For more information on typography best practices see Typgraphy design page.
I hope this helps!
Travis