Smart Clipboard
Smart Clipboard

Every paste, never lost.

A native macOS menu-bar clipboard manager. Records every text, image, and file you copy into a local SQLite database — re-paste any of them with a hotkey, a click, or a terminal command.

macOS 13.0+ Apple Silicon & Intel Open source · MIT Latest:
Features

Built like a Mac app should be.

Tiny binary, native widgets, no Electron, no background daemon, no telemetry. Everything stays on your machine.

📋

Every clipboard change, captured

Polls NSPasteboard every 500 ms. Captures plain text, images (PNG-encoded with thumbnails), and Finder file references.

🔍

Instant full-text search

SQLite FTS5 virtual table indexes every text snippet and file path. Search-as-you-type stays fast with thousands of entries.

⌨️

Global hotkey picker

Default ⌘⇧V (rebindable). Spotlight-style search; pastes into the previously focused app, ⌥↩ copies only.

Star items to keep forever

Starred entries appear in their own menu-bar section. They're excluded from any clear-history operation.

🖥

clip CLI for terminal use

clip list, clip search foo, clip 3 to paste the 3rd item. Implemented via the smartclipboard:// URL scheme — no extra daemon.

☁️

Cloud backup by folder

Point the streamed JSON export at any folder. Pick one inside iCloud Drive, Dropbox, or Google Drive for free cloud sync.

🪶

5 MB and single-process

Native Swift/SwiftUI, no helper daemons, no menu-bar swarm. Storage is a single SQLite file you can back up with cp.

🔓

Open source · MIT

Every line of code is in the repo. Build from source yourself, or download the signed DMG release.

Installation

Up and running in 60 seconds.

Download the DMG, drag to Applications, grant two permissions. That's it.

Option A — one-line installer (recommended)

Downloads the latest DMG, copies the app into /Applications, removes the macOS quarantine flag, and launches it. No Gatekeeper dialog.

curl -fsSL https://raw.githubusercontent.com/tech-sumit/SmartClipboard/main/scripts/install.sh | bash

Option B — manual DMG install

Download the DMG

Grab SmartClipboard-x.y.z.dmg from the latest release on GitHub.

⬇ Get latest release

Drag to Applications

Open the DMG and drag Smart Clipboard into the Applications shortcut.

Bypass Gatekeeper

Because the DMG isn't notarized, macOS shows "Apple could not verify…" on first launch. See the box below for the bypass on your macOS version.

The "Apple could not verify…" warning — how to bypass:
  • macOS 14 Sonoma or earlier: right-click the app in /ApplicationsOpenOpen in the dialog.
  • macOS 15 Sequoia or later: double-click (you'll get the warning), then open System Settings → Privacy & Security, scroll to the "Smart Clipboard was blocked" banner, click Open Anyway, enter your password.
  • From a terminal (any macOS version):
    xattr -dr com.apple.quarantine /Applications/SmartClipboard.app
    open /Applications/SmartClipboard.app
Why the friction? Apple requires a paid Apple Developer Program membership ($99/year) plus notarization for a frictionless install. The DMG is ad-hoc signed only — a notarized release is on the roadmap.

…or build from source

You'll need Xcode 14+ and XcodeGen.

# clone, generate the Xcode project, open in Xcode
brew install xcodegen
git clone https://github.com/tech-sumit/SmartClipboard.git
cd SmartClipboard
xcodegen generate
open SmartClipboard.xcodeproj   # then ⌘R

Or fully from the command line:

xcodebuild -project SmartClipboard.xcodeproj \
           -scheme SmartClipboard \
           -configuration Release \
           -derivedDataPath .build build

cp -R .build/Build/Products/Release/SmartClipboard.app /Applications/
open /Applications/SmartClipboard.app
Permissions

Two prompts. No surprises.

Smart Clipboard asks for exactly what it needs, and the picker still works (partially) if you say no.

PermissionUsed forWhen you'll see the promptIf you deny
Accessibility Synthesizes ⌘V into the focused app when you press Enter in the picker. Uses CGEventPost. You click Request in Settings → Permissions, or paste-on-Enter is attempted for the first time. The picker still restores items to the clipboard — you press ⌘V yourself.
Input Monitoring The global ⌘⇧V hotkey. Uses Carbon's RegisterEventHotKey. First time the hotkey fires after launch. The hotkey won't fire; menu bar and CLI still work fully.
No Full Disk Access Not requested. The app only reads/writes its own Application Support folder.
Where the prompts live afterwards: System Settings → Privacy & Security → Accessibility and … → Input Monitoring. Smart Clipboard will appear in both lists; toggle it on or off any time.
Usage

Three ways to paste.

Click the menu bar, press a hotkey, or use the CLI. Same database under the hood.

From the menu bar

Click the clipboard glyph in the menu bar to see starred items (always pinned) and the most recent items. Clicking an item restores it to the clipboard and pastes it into the app you were just using.

  • Click — restore + paste into previous app.
  • Option-click — restore only, you press ⌘V.
  • ⌘1 … ⌘9 inside the open menu — quick-paste top 9.

From the hotkey picker

Press ⌘⇧V anywhere. A floating non-activating panel appears with a search field. The app you came from keeps keyboard focus, so when you press Enter the paste lands in the right place.

  • — navigate
  • — restore + paste · ⌥↩ — copy only
  • ⌘F — star/unstar · ⌘⌫ — delete
  • — close picker

From the terminal — clip

Install the CLI from Settings → CLI → Install. It creates a symlink at /usr/local/bin/clip (or ~/bin/clip if the former isn't writable).

$ clip list
1 42 ★ TODO: refactor auth module
2 41 git rebase -i HEAD~5
3 39 https://news.ycombinator.com/item?id=…
4 38 npm run dev
5 36 ssh me@10.0.0.42
$ clip search rebase
1 41 git rebase -i HEAD~5
2 37 git rebase --autostash main
$ clip 2  # pastes "git rebase -i HEAD~5" into this terminal

Full CLI reference

CommandWhat it does
clipOpen the picker (same as ⌘⇧V).
clip listPrint the 50 most recent items as INDEX ID ★ PREVIEW.
clip search QUERYPrint recent items matching QUERY (FTS5 prefix match).
clip NPaste the Nth most recent item into the current terminal.
clip id <ID>Paste the item with the given database ID.
clip copy NCopy the Nth item to the clipboard without pasting.
clip helpShow this help.
How it works

One process. One SQLite file. Zero magic.

Smart Clipboard is a single LSUIElement Swift app. There's no helper daemon, no IPC layer, no background launchd job — just a polling loop and a database.

Architecture diagram

1. Capture

A background DispatchSourceTimer reads NSPasteboard.changeCount every 500 ms. When it changes, the new payload (text, image, or file URLs) gets read and inserted into SQLite via GRDB.swift.

2. Dedup

If the new payload is byte-equal to the most recent row, the existing row's created_at is bumped instead of inserting a duplicate. Self-writes (when Smart Clipboard restores an item) are suppressed by a fingerprint check.

3. Search

A SQLite FTS5 virtual table mirrors the preview and text_content columns. Queries split on word boundaries and append * for prefix matching, so search stays sub-millisecond at any size.

4. Restore

To paste an item, Smart Clipboard writes the payload back to NSPasteboard.general, activates the previously focused app, polls for isActive for up to 200 ms, then synthesizes ⌘V via CGEventPost.

5. Hotkey

The global ⌘⇧V is registered with Carbon's RegisterEventHotKey — same API native macOS apps have used for two decades. Rebinding from Settings unregisters and re-registers.

6. CLI bridge

The clip command is a tiny shell script that runs open "smartclipboard://paste?id=…". The main app handles the URL via application(_:open:), so there's no separate daemon or socket to manage.

7. Backup

Auto-backup is streamed: rows are read 50 at a time from SQLite and written incrementally to a temp file, then atomically renamed. Even with thousands of multi-megabyte images, peak memory stays small.

8. Where it lives

Everything is in ~/Library/Application Support/SmartClipboard/clipboard.sqlite (WAL mode). Settings live in UserDefaults. No network calls, ever.

Backup & sync

Cloud backup is a folder choice.

There's no Google account to link, no OAuth dance. Pick a folder that's already syncing to the cloud and Smart Clipboard writes to it.

Manual export & import

Settings → Backup → Export Now writes smartclipboard-backup.json to your chosen folder. Import… appends a previously-exported file to the current DB.

Automatic background export

When enabled, Smart Clipboard rewrites the JSON file 30 seconds after the last clipboard change (debounced). The write is streamed and atomic, so partial files never appear.

Recommended folder paths

ServiceFolder to choose
iCloud Drive~/Library/Mobile Documents/com~apple~CloudDocs/SmartClipboard/
Dropbox~/Dropbox/SmartClipboard/
Google Drive (desktop app)~/Google Drive/My Drive/SmartClipboard/
OneDrive~/Library/CloudStorage/OneDrive-Personal/SmartClipboard/
Heads up: the export contains every captured payload in cleartext (text + base64 images). Don't auto-export to a folder shared with other people or publicly accessible.
Data & privacy

What's stored, and what isn't.

Stored locally

  • Plain-text content of every text copy.
  • PNG-encoded image data + a 64px thumbnail for every image copy.
  • File URLs for every Finder file/folder copy.
  • Bundle identifier of the app that was frontmost when you copied.
  • Timestamp, byte size, and a preview string for the menu.

Never collected, ever

  • Network calls of any kind. No telemetry, no crash reports, no analytics.
  • Encrypted contents from your keychain — those are stored separately by macOS.
  • Anything outside ~/Library/Application Support/SmartClipboard/.

Known tradeoffs

Passwords are captured. When you copy from a password manager, the cleartext password lands on the system pasteboard for a moment — long enough for Smart Clipboard's poller to read it. Items flagged org.nspasteboard.ConcealedType / TransientType are not filtered in v1. Use Settings → Data → Clear unstarred to prune, or open the SQLite file with any tool and delete specific rows.
Unlimited history. Smart Clipboard never auto-evicts. Storage grows over time, but a clipboard manager's database is dominated by screenshots and small text — typical daily growth is single-digit megabytes. Menu → Clear Unstarred History wipes everything that isn't pinned.
FAQ

Frequently asked.

Why does macOS say "Apple could not verify Smart Clipboard is free of malware"?

The release DMG is signed with an ad-hoc identity, not an Apple Developer ID + notarization. macOS Gatekeeper refuses unnotarized apps on first launch.

The easy fix — use the one-line installer at the top of Install; it removes the quarantine flag for you.

Manual bypass — on macOS 14 Sonoma, right-click → Open. On macOS 15 Sequoia, you have to go to System Settings → Privacy & Security and click Open Anyway. From the terminal: xattr -dr com.apple.quarantine /Applications/SmartClipboard.app works on every version.

A notarized DMG (no warning at all) is on the roadmap and requires a paid Apple Developer Program membership.

How do I get the picker on top of my full-screen app?

The picker panel is configured with collectionBehavior including .fullScreenAuxiliary and .canJoinAllSpaces, so it floats above any full-screen window. If it doesn't appear, ensure Smart Clipboard has Input Monitoring permission (System Settings → Privacy & Security → Input Monitoring) so the hotkey can fire at all.

Why does pressing Enter not paste into my terminal?

That requires Accessibility permission (so Smart Clipboard can synthesize ⌘V). Open Settings → Permissions in Smart Clipboard, click Request, then enable the toggle in System Settings. Restart Smart Clipboard once.

Does Smart Clipboard work with Raycast / Alfred / Maccy?

Yes — they don't conflict at the system level. Just make sure your global hotkey isn't claimed by another app; ⌘⇧V is also Raycast's clipboard-history default, for example. Rebind whichever you prefer.

Where is the database file?

~/Library/Application Support/SmartClipboard/clipboard.sqlite (plus -wal and -shm sidecar files from SQLite WAL mode). You can sqlite3 it directly to inspect or query.

How do I uninstall it cleanly?

Quit the app (menu bar → Quit Smart Clipboard), drag /Applications/SmartClipboard.app to the Trash, then delete:

  • ~/Library/Application Support/SmartClipboard/
  • ~/Library/Preferences/com.shailka.SmartClipboard.plist
  • /usr/local/bin/clip (if you installed the CLI)

Remove the entries from System Settings → Privacy & Security → Accessibility and … → Input Monitoring.

Why no rich text / HTML capture?

v1 stores plain text only. Rich-text capture (preserving formatting from browsers and word processors) is on the v2 roadmap — it requires more careful pasteboard-type handling to avoid pasting a styled blob into a terminal.

How do I sync between two Macs?

Today: point auto-backup at an iCloud Drive / Dropbox / Drive folder on both Macs and run Import… when you want to merge. Native CloudKit sync of starred items is on the v2 roadmap.

Is this safe for an enterprise machine?

It stays entirely on-device, makes zero network calls, and the only API capabilities it uses (NSPasteboard, Carbon hotkey, Accessibility for paste) are visible in the app sandbox/entitlements. That said: the database is unencrypted at rest and captures everything, including secrets. Review with your security team before deploying on an enterprise fleet.

Roadmap

What's next.

v1 is intentionally small and self-contained. These are the upgrades on the table.

☁️

CloudKit sync

Native cross-Mac sync of starred items via iCloud. No folder trickery required.

🔐

Encryption at rest

Optional AES-encrypted SQLite database with a passphrase, for storing sensitive copies.

🛡

Concealed-type filtering

Opt-in to honor org.nspasteboard.ConcealedType from 1Password, Bitwarden, etc.

📝

Rich-text capture

Preserve RTF/HTML formatting from browsers and word processors.

🏷

Tags & snippets

Group items into named collections; templated snippets with {{ placeholders }}.

Notarized DMG

Apple Developer-ID-signed and notarized release so first-launch needs no right-click.