These posts are being re-created from old Jamf Nation posts not because they are the best but because they may have useful things that were mangled in the Jamf Nation transition to its most recent hosting platform.
That, & they were always supposed to be blog posts anyway… I didn’t have a blog then.
UTI in this domain unpacks to “Uniform Type Identifier” not “Urinary Tract Infection”. Get your mind out of the gutter…
Type identifiers built into macOS / iOS allow files to open in a specified application by default. The system also enables “custom routing” of a file extension to a 3rd party application. This is useful in managed environments: my example below tells macOS that Microsoft Outlook should be the default application for calendar files instead of the native macOS Calendar app.
End users often have to click on calendar file attachments in email. If files don’t open in the applications workers are forced to use by the organizations they work for, it’s not just an inconvenience. It’s a real problem.
There’s always been a little mystery & difficulty surrounding UTI managment, starting with duti up to SwiftDefaultApps (swda) & beyond.
Now, there’s a new UTI problem from the legendary Armin Briegel:
In macOS 26.4 Apple has added user confirmation prompts to all file type / UTI default app changes.
Note: exactly which kind of default app changes causes the prompt to appear has changed during the beta phase of macOS 26.4. There might be changes to this in later updates. If so, I will update this article accordingly.
Note 2: users can still change default apps for file types in the Finder Info window without an additional prompt.
More on the topic:
- https://scriptingosx.com/2025/07/updates-setup-manager-and-utiluti/
- https://community.jamf.com/tech-thoughts-180/managing-the-default-browser-in-macos-53418
So, what does this mean? Well, it may mean that Armin’s tool utiluti and swda are a bit less useful than before.
There is something slightly encouraging from the developer on the swda GitHub page though:
ANNOUNCEMENT: I have recently noticed Apple has introduced replacements for the deprecated APIs used in this prefpane. As a result, slow as it may be, I plan to resume development. I will be taking PRs as well, if somebody wishes to contribute.
Maybe updates to the API mean that will hear the wailing & gnashing of teeth from Mac admins everywhere & finally make this system easier to manage.
SCCM
Valued Contributor
February 15, 2022
Does anyone know if there is a custom config / plist way to set the default mail app to outlook?
I know there is a microsoft support tool which can do it, but requires user interaction. I’ve found some old methods with mcx’s which no longer work and some bash scripts using duti.
I am just trying to see if there is an easier / better way to do it via config profile on monterey?
…
brockwalters
Valued Contributor
May 12, 2022
@pete_c Thanks for the recommendation of SwiftDefaultApps.
Though I finally found this article: https://aporlebeke.wordpress.com/2020/07/16/configuring-a-macs-default-apps-for-different-file-types/ I did not find many examples of how to use it (there are some from @ryan_ball in comments on Jamf Nation) so I thought I would write this up quickly here.
It’s not the most intuitive CLI I’ve ever used 😗 but it works great & the help is good once you understand there are multiple pages (somewhat like the jamf binary…)
Calling the binary with no options gets you this:
% swda
Utility to retrieve and manipulate default applications in macOS.
Available commands:
- getHandler Returns the default application registered for the URI Scheme or <subtype> you specify.
- getApps Returns a list of all registered applications.
- getSchemes Returns a list of all known URI schemes, accompanied by their default handler.
- getUTIs Returns a list of all known UTIs, and their default handler.
- setHandler Sets <application> as the default handler for a given <type>/<subtype> combination.
- help Prints this help information
- version Prints the current version of this app
To get help on the “Available commands” that have additional options do this:
% swda getHandler
Usage: swda getHandler <type> [options]
<type>
--URL <subtype> Return the default application for <subtype>
--UTI <subtype> Return the default application for <subtype>
--ftp Returns the default FTP client.
--internet, --browser, --web Returns the default web browser.
--mail, --email, --e-mail Returns the default e-mail client.
--news Returns the default news client.
--rss Returns the default RSS client.
[options]
--all When this flag is added, a list of all applications registered for that content will be printed.
--role <role> Specifies the role with which to register the handler. Default is All.
-h, --help Show help information for this command
Missing options: <type>: --UTI, --URL, --internet, --browser, --web, --mail, --email, --e-mail, --ftp, --rss, --news
The script I ended up using it in (which was executed in a Jamf Policy “after” executing a custom .pkg that installed the swda binary):
#!/bin/sh
# the swda binary is the CLI for SwiftDefaultApps
# https://github.com/Lord-Kamina/SwiftDefaultApps/releases
# this binary allows an app (i.e., "handler") to be assigned to any available file extension
/bin/chmod 755 '/usr/local/bin/swda'
/usr/bin/xattr -c '/usr/local/bin/swda'
/usr/sbin/chown 0:0 '/usr/local/bin/swda'
# sets Handler (application) for .ics files (which defaults to Apple Calendar) to Microsoft Outlook
/usr/local/bin/swda setHandler --app '/Applications/Microsoft Outlook.app' --UTI 'com.apple.ical.ics'; /bin/sleep 1
/usr/local/bin/swda setHandler --app '/Applications/Microsoft Outlook.app' --UTI 'com.apple.ical.ics.event'; /bin/sleep 1
/usr/local/bin/swda setHandler --app '/Applications/Microsoft Outlook.app' --UTI 'com.apple.ical.ics.todo'; /bin/sleep 1
# check settings
/usr/local/bin/swda getHandler --UTI 'com.apple.ical.ics'; /bin/sleep 1
/usr/local/bin/swda getHandler --UTI 'com.apple.ical.ics.event'; /bin/sleep 1
/usr/local/bin/swda getHandler --UTI 'com.apple.ical.ics.todo'; /bin/sleep 1
Source: https://community.jamf.com/general-discussions-2/set-default-mail-app-outlook-26753