What’s new in SwiftUI

Dive into the latest features and capabilities of SwiftUI. The 2027 releases bring major upgrades to SwiftUI, a powerful new Document API, expanded toolbar controls, and significant performance improvements to build times and data flow.


Xcode 27 agent skills

Xcode 27 helps you adopt new SwiftUI APIs and best practices with a set of skills that you can use in the coding assistant. The skills apply SwiftUI conventions throughout your code, and guide you through the new APIs from the 2027 releases.


Toolbar customization

New toolbar APIs give you precise control over how items are displayed as your app resizes. Use the visibilityPrioritymodifier to keep key groups visible, toolbarOverflowMenu to permanently place lower-priority items in an overflow menu, and topBarPinnedTrailing to pin critical actions — like a share button — to the trailing edge at all times. The new toolbarMinimizeBehavior modifier automatically collapses the navigation bar when scrolling.


Document API

The expanded SwiftUI Document API gives you direct control over the structure of your saved documents. For reading and writing, conform to WritableDocument and ReadableDocument, which offer asynchronous, incremental disk operations and progress reporting via the Foundation Subprogress API. The DocumentCreationSource API lets you declare multiple creation sources with a NewDocumentButton for each.


Presentation and interaction

New reorderable container APIs let people drag to rearrange items in any container — not just List — using the same code across List, LazyVGrid, and more. Reordering comes to watchOS for the first time. Add swipeActionsContainer to any ScrollViewto enable them across your layout. Confirmation dialogs and alerts now support the same item-binding pattern used by sheets, so presentations appear automatically when a bound value is set.


Performance and data flow

AsyncImage now supports standard HTTP caching by default, respecting server cache headers without any code changes. For more control, pass a custom URLRequest or configure a URLSession with a tailored URLCache using the asyncImageURLSessionmodifier. Classes stored in @State are now initialized lazily — only once per view lifetime — thanks to State becoming a macro. Build times in Xcode 27 improve significantly through changes to ViewBuilder, now exposed as ContentBuilder.


Features are subject to change. Some capabilities and services may not be available in all regions or all languages; some feature availability may vary due to local laws and regulations.