QLCodePreview
Space-bar any source file in Finder and see it colourised. A Quick
Look preview extension built on the app-extension API, now that Apple
has retired the .qlgenerator plugins the old tools
relied on.
Highlights
Nothing on this list is a roadmap. It's all in the current build.
Self-contained
The highlighter is built from scratch and runs inside the sandboxed extension. Nothing to install alongside it.
Fast
A 2 MB file previews in about 130 ms: keyword lookup is a set scan, and each colour crosses the wire once as a CSS class, not once per token.
Tunable
Font and size, light and dark themes, line numbers, soft-wrap, tab width, and a max file size past which it won't render.
Bring your own file types
Map any file extension to a language in settings; install → php is the canonical example. The Drupal filetypes that started this whole thing in 2012 are a settings tab now, not a fork.
Languages
Source, config, markup: dozens of languages, and anything unknown falls back to plain text.
The full extension map
Unknown extensions fall back to plain text, and any extension can be remapped in the app's Custom File Types pane.
Get it
Donationware, and installing is one command.
- 1 Install itThe easy way is Homebrew: brew trust konstruukt-labs/tap(one-time; current Homebrew requires it for third-party taps), thenbrew install --cask konstruukt-labs/tap/qlcodepreview. Or grab the latest notarised build from GitHub ↗. It's a universal zip (arm64 + Intel), built and tested on Apple Silicon. Building from source works too:./build.sh installneeds nothing but Apple's Command Line Tools, no Xcode.
- 2 Flip the switchRun QLCodePreview once (the toggle only appears after the app has been run), then System Settings → General → Login Items & Extensions → Extensions → QLCodePreview = ON. The one step macOS won't let a script do.
- 3 Space-bar somethingAny source file in Finder, colourised on the spot.
Support development
The app is free, but making it isn't: Apple Developer Program membership and everything hosted around the app cost real money. If QLCodePreview earns its keep on your Mac, there's a coffee link in the app's footer, or the button right here.