How do I create a floating tab bar view?
Asked on 06/11/2025
1 search
To create a floating tab bar view in your app, you can use the new design features introduced in SwiftUI and UIKit. Here's how you can achieve this:
SwiftUI
-
Floating Tab Bar: In SwiftUI, the tab bar can float above the content and be configured to minimize and scroll. To adopt this behavior, use the
Tab Bar Minimize Behavior
modifier. For example, you can set the behavior toonscroll down
, which will re-expand the tab bar when scrolling in the opposite direction. -
Tab View Bottom Accessory: If you have additional controls that you want to keep close at hand, you can place a view above the tab bar using the
Tab View Bottom Accessory
modifier. This allows you to take advantage of the extra space provided by the tab bar's collapsing behavior. -
Sidebar Adaptable Style: If your app is currently using a tab bar, you can try out the sidebar appearance by setting a
tab view style
ofsidebar adaptable
. This will make your tab bar appear as a sidebar, which is useful for apps with a lot of content.
UIKit
-
Floating Tab Bar: In UIKit, the tab bar can also float above the content. To allow the top bar to minimize on scroll, set the
top bar minimize behavior
to the desired direction, such asonscroll down
. -
Bottom Accessory: To set a bottom accessory, create a
UITabAccessory
with your content view and set thebottom accessory
property onUITabBarController
. This will display the accessory view above the tab bar, matching its appearance.
For more detailed guidance, you can refer to the sessions from WWDC:
These sessions provide insights into how to implement and customize the floating tab bar in both SwiftUI and UIKit.

Build a SwiftUI app with the new design
Explore the ways Liquid Glass transforms the look and feel of your app. Discover how this stunning new material enhances toolbars, controls, and app structures across platforms, providing delightful interactions and seamlessly integrating your app with the system. Learn how to adopt new APIs that can help you make the most of Liquid Glass.

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.

Elevate the design of your iPad app
Make your app look and feel great on iPadOS. Learn best practices for designing a responsive layout for resizable app windows. Get familiar with window controls and explore the best ways to accommodate them. Discover the building blocks of a great menu bar. And meet the new pointer and its updated effects.