Hi, I'm PipThese Featured apps take turns in my notch.
iPipSubmit

← All tools

Menu bar icon checker

Drop your menu bar icon below. It is drawn right here on this page, and the picture is never uploaded.

Menu bar icon checker

Try an example:

What it does

Drop in the small icon your Mac app puts in the menu bar, the one Apple calls a menu bar extra, as a PNG or an SVG. The tool draws it on a light and a dark menu bar, as a template image and in its own colors, and in the selected state. Then it checks what makes menu bar icons look wrong: colors in a picture meant to be a template, a picture taller than the bar, a drawing too small or too big for it, a missing Retina copy, and an icon that fades into the bar when it is not a template. This is for the menu bar icon. For your app icon in the Dock and Finder, use the Mac icon checker.

What Apple says

Apple's Human Interface Guidelines say the menu bar is 24 pt tall, and suggest a symbol for a menu bar extra, either an SF Symbol or your own. Interface icons and symbols use black and clear to define their shape, and the system applies other colors to the black parts, so the icon looks right on dark and light menu bars and when it is selected. Apple's AppKit documentation says template images should be only black and clear, and that the alpha channel can change how opaque the black is. For your own interface icons, Apple suggests a vector format such as PDF or SVG.

Apple does not give a point size for menu bar icons. The 10 pt and 22 pt marks in the checks are our rule of thumb, and the tool says so where it uses them.

How to make it a template image

// AppKit
let item = NSStatusBar.system.statusItem(withLength: NSStatusItem.variableLength)
let image = NSImage(named: "MenuIcon")
image?.isTemplate = true
item.button?.image = image

// SwiftUI, macOS 13 or later
MenuBarExtra("Zorbclip", image: "MenuIcon") { ContentView() }

In Xcode you can also select the image set in your asset catalog and set Render As to Template Image. An SF Symbol is a template already.

How the checks work

The picture is drawn in your browser and every pixel is read. Pixels that are almost clear are left out. A pixel counts as colored when its red, green and blue are far apart, and as gray or white when they are close together but not dark. Sizes in points are the pixels divided by the scale. The tool guesses the scale from the file name (@2x, @3x) or the height, and you can set it yourself. Contrast uses the WCAG 2 formula against two flat bar colors. The real menu bar is see-through and takes on the colors of the wallpaper, so the previews and the ratios are close, not exact.

What each result means

MarkWhat it means
OKThis part is ready.
LookIt works, but it may look wrong for some people, or it is not what Apple asks for.
NoteWorth knowing, nothing is broken.
FixThe icon will look broken in the menu bar until this changes.

Questions

What size should a Mac menu bar icon be?

Apple gives the menu bar a height of 24 pt and no fixed size for the icon, so the picture has to fit inside 24 pt, with a little room above and below. Ship a @2x copy, or a PDF or SVG, so it stays sharp on Retina screens.

What is a template image?

An image that macOS colors for you. It should be only black and clear. The system draws it so it looks right on light and dark menu bars and when it is selected.

Why does my menu bar icon disappear in dark mode?

Usually because it is not a template image. A black icon shown in its own colors fades into a dark menu bar. Mark it as a template, with isTemplate in code or Render As Template Image in the asset catalog.

Is my icon uploaded anywhere?

No. The picture is read and drawn in your browser, and nothing is sent.

Related