So you want to create a macOS app …
Great! It’s a very nice platform, the tools are mature, the community is welcoming, and the results can look super nice.
Common UI Components
The Cocoa Text System
Aka “Text Kit” on iOS. This revolves around everything related to writing: NSTextView for the UI component, NSTextStorage for the processing of text and style changes, NSLayoutManager for the computation of line and glyph sizes, and for applying styles, NSTypesetter for putting glyphs on the screen.
All my posts on the text system are collected in the TextKit overview.
NSDocument
- Blog Series: TableFlip’s NSDocument File Type Issues and Fixes
- Related file types: for example, a movie file and its subtitles file.
Distributing Mac Apps
Paddle
FastSpring
I sell my apps via FastSpring, and I like what they offer. So I’m both knowledgable about their service and personally invested. I think what they offer is great and very flexible.
Now I wrote a ton about FastSpring already, including an ebook guide. I’ll not repeat everything here.
Find out more on my comprehensive list of tips, tools, and resources on How to Sell Mac Apps With FastSpring
Posts on Mac app development
FreeBSDKit: Swift Package to Write Capability-Aware FreeBSD Apps
FreeBSDKit is a Swift Package to e.g. work with FreeBSD Jails, kqueue, Capsicum sandboxing.
Xcode 26 LLM Markdown Summaries Are Actually Useful for Humans
Xcode 26 has a couple of tech docs that are intended to help LLM’s generate modern solutions to coding problems in Swift, but that also contain valuable info for us human readers.
Auto-Mount Metal Toolchain Using a Launch Service Because Xcode 26 Cannot
Xcode 26 is incapable of compiling Metal shaders on my machine, so I need to help out to mount the appropriate toolchain with a Launch Service
Manually Mount the Metal Toolchain When Xcode Cannot
My computer suffers from Xcode not being able to access the Metal toolchain that is clearly installed on my system. I need to mount the disk image manually to fix this and make the CompileMetalFile error go away.
Adapt Unidirectional Flow Virtues to Your Plain SwiftUI App
To get started, you can require authentication for actions on buttons anywhere in your SwiftUI app produce a change up the scene, e.g. a log-in overlay or dialog, by injecting a closure into the environment to handle that.
SwiftUI DocumentGroups Are Terribly Limited
Document-based apps with SwiftUI are easy to write, but hard to customize apart from a couple visual tweaks. Say if you want to introduce in-app purchases.
Start of a Zettel: Modern UICollectionView
A Zettelkasten is a tool for learning. How do I learn a new piece of a familiar API at the very start?
NSFileWrapper Sometimes Changes Modification Date to the Past
Beware when overwriting files with the same content using NSFileWrapper: the modification date can mess up.
Using 2 Editors Because Xcode Is Dumb
Xcode 16 doesn’t support working on a Package and a Demo app at the same time. But other editors do.
Free SwiftUI University Course fro -Boston College Professor
If you need a free resource to make apps with SwiftUI in 2025, this one might be for you.
Running Unsigned Applications on macOS Sequoia
“Open Anyway” for unsigned apps is now located in settings.
Composition Over Inheritance in NSViews
I noticed that I’m writing some AppKit/UIKit view components in a composable way that reminds me of the opaque nature of SwiftUI.View-conforming types: hiding away the actual 1st party APIs, providing very little surface area.
PSA: SwiftUI Button Click-Through Fixed in macOS 15
SwiftUI non-bordered button styles don't support click-through up to macOS 15, but are fixed with the upcoming macOS release.
MacMenuBar – Directory of Hundreds of Menu Bar Apps
Invaluable resource to see trends in menu bar app UIs and to discover cool tools: macmenubar.com lists 950+ menu bar apps (as of June 2024)
Table View Cells from Nib: How to Change the Blueprint Data to Affect New Cells
Deep dive into where the little cells come from, the old school way: Inspecting call stacks, probing default objects. The goal is to change how cells spawn from Nibs.
SwiftUI Kata: Recreating DebugInfo Viewer
Recreating the “DebugTest Info” app from the Mac OS X era from Technical Note TN2124 in SwiftUI with macOS Sonoma default styling.
Enable SwiftUI Button Click-Through for Inactive Windows on macOS
Buttons in macOS windows both activate a background window and perform the button action with one click. That so-called click-through behavior breaks with almost all SwiftUI button styles, including custom ones. Here is a fix.
SwiftUI Challenge: Can You Port this from Auto Layout to SwiftUI?
“Der Teilweise” proposed an interesting benchmark to see whether SwiftUI is production ready. Takes 10 minutes to do in Auto Layout. How long do you need for SwiftUI?
Chris Eidhof released an interactive, animated resource to understand SwiftUI.
Turns out that even when the overflow menu items look clickable, not all of them actually fire an event. You need to tell the NSMenuItem about its action.
Ignore Generated Xcode .xcworkspace Files in Git Except Package.resolved
To tell your teammates’ Xcode that packages need to be updated after a pull, check in the resolved packages file from within the Xcode project bundle. Here are git ignore rules to help you with that.
After starting the day with a pro-SwiftUI rant, to my surprise I end it with an embrace of traditional, tested and true AppKit patterns.
Not Quite 100% SwiftUI – Time Makes Perfect
Marin Todorov's “A 100% SwiftUI App” talk from this year's Swift Heroes went life (and it's really worth the half hour!)
Sparkle v2.5 Adds Relevant Version Highlighting to Release Notes
With Sparkle v2.5, you can ship release notes for multiple versions, and then use CSS to hide outdated information from the user.
Async XCTest Assertion Helpers
The missing XCTAssert helpers that support async calls: AsyncAssertTrue(try await shouldSucceed())
Summary of how the responder chain is traversed on macOS to have events bubble up.
SwiftUI.View Is Your ViewModel
Hypothesis: You already have a View Model when you work with SwiftUI, which is the View type itself.
Decoupling SwiftUI.View Configuration from Layout and Action Handling
Decoupling introduces independence, which means the de-coupled pieces can change independently. Even in the smallest view component, this can bring tangible real-world improvements.
Super Saturday Sharefest: Matt Massicotte's XPC Work
Shout-out to Matt Massicotte for sharing yet another XPC and Concurrency related open source package!
Swift Package Import in Objective-C Might Just Work
Unbeknownst to me, you can @import Swift Packages in Objective-C files just fine!
SwiftUI.List with Menu with Plain Button Style Breaks Event Loop
Super weird edge case: the plain button style makes interacting with the menu all but freeze the app. (FB12285575)
How to Inspect SwiftUI.TextField.onSubmit and Figure Out You Can't Programmatically Use It
I looked for a way to trigger the onSubmit block in my own code, but none of my approaches bore fruit.
NSTableView Variable Row Heights Broken on macOS Ventura 13.0
Variable row heights are broken on Ventura’s initial release. In macOS 15 Sequoia, the same feature may produce blurry text.
Sketch Layoff of 80 Employees — Does It Really Send an Alarming Signal?
SwiftUI Isn't Easy to Get Into: My Road From Headache Towards Mastery
SwiftUI Requires Platform Knowledge On Top. Case Study: Fonts
How to Fix Mach-O Header Code 0x72613c21 When You Try to Export Your App in Xcode
How to Print on macOS With An NSTableView and Customize the Result
NSSavePanel Crashes on Big Sur for public.csv UTI When You Don't Have a CSV Editor
Upgrading to Sparkle 2.x Branch
The Sparkle 2.x release branch is working fine for production when you switch from the ui-separation-and-xpc branch and enable DSA signing of updates.
Blog Series: TableFlip's NSDocument File Type Issues and Fixes
How to Create a NSSavePanel accessoryView in Swift to Pick File Formats
Programmatically Select a NSSavePanel File Format to Fix Empty Selections
Observations of the Curious Problem of NSDocument-Based App Changing the File Extension
AppMover Swift Library to Move Your macOS App to the Applications Folder
That Weird Obstable of Interface Builder When You Get Started With iOS Development
"Make Money Outside the Mac App Store" Second Edition Ebook Available
NiftyMenu -- Automatically Recreate a macOS App Menu Bar in HTML
Xcode Project Setup to Build, Embed, Codesign, Notarize, and Use the Sparkle XPC Services
Use Shared NSUserDefaults for XPC and Interface Builder Nibs
Fix NSSegmentedControl Action Forwarding from Your NSToolbar
NSTextField usesSingleLineMode Stops Working When You Implement NSTextViewDelegate Methods
Put Test Files Next to Production Code for Better Discoverability?
macOS Storyboard Outlet-Like Connections Between View Controllers
Fixing NSTableView Cell Backgrounds by Deactivating NSSplitViewItem's Visual Effects
Drawing Custom Alternating Row Backgrounds in NSTableViews with Swift
First Contact with AppKit for iOS Developers (Under the Radar #26)
Extend View Controllers with Behavior Objects Right from Within Interface Builder
Make Money Outside the Mac App Store now Available on Amazon
Don't Build on El Capitan Without Checking App Transport Security
Make Custom Debug Build Configurations Play Nicely With CocoaPods