explaingit

hreinssondev/anypip

21SwiftAudience · generalComplexity · 1/5LicenseSetup · easy

TLDR

A macOS menu-bar app that turns any app window into a floating picture-in-picture overlay that stays on top of everything else on screen, using keyboard shortcuts you configure yourself, extending PiP beyond video players to any window at all.

Mindmap

mindmap
  root((AnyPiP))
    What it does
      Float any window as overlay
      Stays on top always
    Controls
      Custom keyboard shortcuts
      Manual toggle on off
      Auto-PiP per app
    Permissions needed
      Screen Recording
      Accessibility
    Tech stack
      Swift
      SwiftUI
      ScreenCaptureKit
      AppKit
    Requirements
      macOS 26.4 or later
      MIT license
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

Things people build with this

USE CASE 1

Float a reference window like a Slack chat or documentation page as a persistent overlay while you work in another full-screen app.

USE CASE 2

Automatically keep a specific app visible as a floating overlay whenever you switch focus away from it.

USE CASE 3

Replace a second monitor by floating reference windows as persistent overlays on a single screen.

Tech stack

SwiftSwiftUIAppKitScreenCaptureKit

Getting it running

Difficulty · easy Time to first run · 5min

Requires macOS 26.4+ and must grant both Screen Recording and Accessibility permissions before the floating overlay feature will work.

MIT license, use, modify, and distribute freely for any purpose, including commercially, as long as you keep the copyright notice.

In plain English

AnyPiP is a macOS menu-bar app that takes any visible app window and floats it as a picture-in-picture overlay above everything else on your screen. Picture-in-picture on macOS normally only works with video players, AnyPiP extends that idea to any window at all. The app sits in your menu bar and activates through keyboard shortcuts you configure yourself. One shortcut turns the frontmost window (whatever is currently in focus) into a floating overlay that stays on top of other apps. A second shortcut restores that floating window back to its original position or closes it. There is also an auto-PiP option: you can tell the app to automatically float certain apps whenever you switch focus away from them, keeping those windows visible while you work in something else. AnyPiP requires two macOS permissions to function. Screen Recording lets it capture the window content to display in the overlay. Accessibility lets it move, resize, and refocus windows on your behalf. Without both permissions granted, the core features will not work. The app requires macOS 26.4 or later. It is written in Swift using SwiftUI, AppKit, ScreenCaptureKit, and the macOS Accessibility APIs. The README is brief and the source is released under the MIT license.

Copy-paste prompts

Prompt 1
I have installed AnyPiP. Walk me through granting Screen Recording and Accessibility permissions on macOS and setting up my first keyboard shortcut to float a window.
Prompt 2
How do I configure AnyPiP to automatically float my notes app as a picture-in-picture overlay whenever I switch focus to my code editor?
Prompt 3
I am building a macOS app that needs to float windows over other apps using ScreenCaptureKit and the Accessibility API. How does AnyPiP use these frameworks to capture and reposition a window?
Open on GitHub → Explain another repo

← hreinssondev on gitmyhub — every repo by this author, as a profile.

Verify against the repo before relying on details.