Skip to content

Repository files navigation

CopyShot Logo

CopyShot

Fast OCR in your Mac's menu bar

downloads latest version license platform


Select → extract → clipboard. One keystroke (⌘⇧C).
Works on every display, resource friendly, and it’s open source.


Screenshot

Main Features

Feature Description
Drag-to-Capture Any screen area, instantly.
Multi-Monitor Seamless across all displays.
⌘⇧C (or your own) Re-bindable global hotkey.
Vision OCR Accurate & Fast modes, with language correction option.
Image Preprocessing Grayscale and contrast adjustments for better results.
Quick Actions Flyout action bars to transform text, join lines, open URLs/search, and on-device translation.*
Settings Interface Built with SwiftUI for a smooth, native feel.
Auto-Update Background updates powered by Sparkle.
Notifications Includes sound, haptics, icons, and a preview you can tweak.
Resource Friendly Uses minimal CPU and RAM. It's also very small in size.

*Note: On-device translation requires macOS 15.0 (Sequoia) or later. The first time a new language set is used, macOS will prompt you once to download Apple's on-device neural language set directly onto your Mac. Other Quick Actions are fully supported on macOS 14 (Sonoma)+.


Architecture & How It Works

CopyShot runs as an ultra-lightweight menu bar utility (LSUIElement) with a direct, local pipeline:

[Global Hotkey (⌘⇧C)] 
         │
         ▼
[SCScreenshotManager]      ──▶ Retina-scaled single-frame capture (~35ms)
         │
         ▼
[CoreImage Preprocessor]   ──▶ Grayscale (CIPhotoEffectMono) + 50% contrast boost
         │
         ▼
[Apple Vision OCR Engine]  ──▶ VNRecognizeTextRequest + smart reading order assembly
         │
         ├───────────────────────────────┐
         ▼                               ▼
[NSPasteboard (Clipboard)]      [Floating Frosted-Glass HUD]
(Text instantly available)       (Expandable preview + audio feedback)
  1. Hotkey Listening: Carbon event registration intercepts ⌘⇧C globally without requiring Accessibility permissions.
  2. Multi-Monitor Overlay: Full-screen transparent overlay windows open on all connected displays. Dragging cuts out the selected frame over the target text.
  3. Single-Frame Capture: macOS 14+ SCScreenshotManager.captureImage grabs the selected physical display coordinates directly in ~35ms.
  4. Local Neural OCR: Preprocessed with CoreImage, Apple's Vision framework identifies text lines and groups them logically from top-to-bottom and left-to-right.
  5. Immediate Feedback: The recognized text is copied to NSPasteboard.general while an interactive HUD appears on the captured display.

Privacy

CopyShot respects your privacy. All OCR processing happens locally on your device using Apple's Vision framework. The app does not access any of your personal files. Your captured images and extracted text remain entirely on your Mac.

Network Note: Since v1.1, CopyShot requires outbound internet access exclusively and only to check for application updates securely via the Sparkle framework.


Installation

Note: CopyShot requires macOS 14 (Sonoma) or later.

  1. Download the App: Go to the Releases page and download the latest version of CopyShot.

  2. Open the App:

    • Because CopyShot is an open-source tool and not distributed through the Mac App Store, macOS Gatekeeper will block it when tried to open with a message saying "CopyShot Not Opened, Apple could not verify CopyShot is free of malware that may harm your Mac or compromise your privacy.".
    • To bypass this: Go to System Settings > Privacy & Security, scroll down to the bottom, and click Open Anyway where it mentions CopyShot was blocked. You only need to do this once.
  3. Grant Screen Recording Permission:

    • The first time you use CopyShot (by pressing the hotkey), macOS will block it from capturing your screen.
    • Go to System Settings > Privacy & Security > Screen & System Audio Recording.
    • Find CopyShot in the list and enable the toggle.
    • Important: After granting permission, Quit and Reopen CopyShot for the changes to take effect.

Running from source (for developers)

Click to expand

If you'd like to edit, build, test, and run CopyShot yourself on macOS, here's how to get started. See CONTRIBUTING.md for full development guidelines.

Prerequisites

  • macOS 14+
  • Xcode 16+ (free from the App Store)

Steps

  1. Clone the Repo:

    git clone https://github.com/Sayitobar/CopyShot.git
    cd CopyShot
  2. Open in Xcode: Double-click CopyShot.xcodeproj to open it in Xcode.

  3. Build and Run: In Xcode, select the CopyShot target and your desired build scheme (e.g., My Mac). Hit the Run button (play icon) or go to Product > Run. It should build and launch the app.

  4. Run Unit & Benchmark Tests: Press ⌘U in Xcode or run via terminal:

    xcodebuild test -scheme CopyShot -destination 'platform=macOS' -only-testing:CopyShotTests
  5. Grant Permissions: The first time you run CopyShot, macOS security features will prevent it from capturing your screen. You will need to manually grant permission. Here is how to locate Screen Recording Permissions manually:

    • Go to System Settings > Privacy & Security > Screen Recording.
    • Find CopyShot in the list of applications and enable the toggle next to it.
    • Quit and reopen CopyShot for the changes to take effect.
  6. Making Code Changes: If you'd like to make any change to the code:

    • Save your changes.
    • Quit any running CopyShot instances.
    • Delete te given Screen Recording Permission access to all CopyShot instances.
    • Rerun the app and regrant permissions. (If doesn't work, try Product > Perform Action > Run Without Building)

Once it's set up, CopyShot should run & appear in your menu bar. If you're going through all this, thanks for checking it out, you probably know your way around, so feel free to tweak it.

Ideas for future features (suggestions welcome)

Click to expand

Editing Copied Texts

  • Introduce a button below the copy notification to apply various text edit tools for quick edits, like removing line breaks, applying UPPERCASE, lowercase, Title Case, Sentence case, tOGGLE, etc.
  • Possibly integrate an LLM (or a more powerful OCR like DeepSeek-OCR) with your API key and a custom system prompt for editing the text.

OCR Improvements

  • Personal glossary for domain-specific terms.
  • OCR history with instant search & re-copy.
  • Drag-and-drop image files into the app for OCR.
  • Advanced preprocessing: deskew, denoise, adaptive binarization...

Capture Options

  • Capture an entire window or app
  • Countdown timer for captures.
  • Handle scrolling areas for long pages.
  • Option to save captures as images (PNG/JPG).
  • Option to copy the image itself to the clipboard.

Usability and Accessibility

  • Onboarding guide for first-time users.
  • VoiceOver & other accessibility refinements.

About the Project

The first version of CopyShot (v1.0.0) was live-coded with Gemini CLI. Every line, refactor, and bug-fix was done with the help of Gemini. This small experiment showed how far AI-assisted software development has come. Now, the project is maintained with the help of a mix of AI tools and human oversight.

License

This project is licensed under the MIT License - see the LICENSE file for details.

About

An open-source MacOS app to copy text from a screenshot

Topics

Resources

Contributing

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages