how can i make a menubar application on mac
Asked on 06/18/2025
1 search
To create a menu bar application on macOS, you can use AppKit or SwiftUI, depending on your preference and the specific requirements of your app. Here are some key points and resources from WWDC sessions that might help you:
-
AppKit and SwiftUI Integration: You can use SwiftUI menus in AppKit contexts using
NSHostingMenu
, which is a newNSMenu
subclass. This allows you to share menu definitions between parts of your app that use AppKit and those that use SwiftUI. You can create your menu definition using a SwiftUI view in the body. What’s new in AppKit (06:41). -
Building Menus with SwiftUI: SwiftUI provides a convenient way to define menus using its declarative syntax. You can use SwiftUI views to describe the data relationship, such as using a toggle to switch a value on and off, a picker to select one value from a list, and a button to perform an action.
-
Menu Bar Design: When designing a menu bar, it's important to organize your menu items by frequency of use rather than alphabetically. Group related actions into their own sections to create further separation. Avoid hiding menus and menu items to ensure a predictable user experience. Elevate the design of your iPad app (10:24).
-
UIKit Menu Bar: If you're developing for iOS as well, note that iOS 26 brings the menu bar from macOS to iPad, providing a consistent experience across platforms. This can be useful if you're planning to have a cross-platform app. What’s new in UIKit (03:21).
These resources should give you a good starting point for creating a menu bar application on macOS. If you need more detailed guidance, consider watching the full sessions mentioned above for comprehensive insights.

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.

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.

Meet PaperKit
Discover how to bring PaperKit to your iOS, iPadOS, macOS, and visionOS apps. We’ll cover how to seamlessly integrate PencilKit drawing with markup features like shapes and images, and how to customize the user interface. Learn best practices for forward compatibility, and discover advanced customization options to create truly unique markup experiences in your apps.