whatisgithub

What is rectangle?

fieldju/rectangle — explained in plain English

Analysis updated 2026-07-17 · repo last pushed 2023-12-30

SwiftAudience · generalComplexity · 1/5DormantSetup · easy

In one sentence

A free, open-source Mac window manager that snaps windows into halves, quarters, and thirds using keyboard shortcuts or edge-dragging.

Mindmap

mindmap
  root((rectangle))
    Inputs
      Keyboard shortcuts
      Drag-to-edge gestures
      JSON settings file
    Outputs
      Snapped window layout
      Custom shortcut config
    Use Cases
      Snap windows to halves and quarters
      Compare two windows side by side
      Trigger layouts via URL or terminal
    Tech Stack
      Swift
      macOS
    Audience
      Mac power users

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

What do people build with it?

USE CASE 1

Snap a window to the left half of the screen instantly using a keyboard shortcut instead of dragging it.

USE CASE 2

Drag a window to a screen edge and see a live preview of where it will snap before releasing.

USE CASE 3

Customize keyboard shortcuts and exclude specific apps from Rectangle's window snapping.

USE CASE 4

Trigger window layout changes from a terminal command or URL for automation or scripting.

What is it built with?

SwiftmacOS

How does it compare?

fieldju/rectangleaiduckman/claudeusage_latest_may2026arnabau/thermalpulse
Stars00
LanguageSwiftSwiftSwift
Last pushed2023-12-30
MaintenanceDormant
Setup difficultyeasyeasymoderate
Complexity1/52/53/5
Audiencegeneralvibe coderdeveloper

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · easy Time to first run · 5min
Free and open source, specific license terms are not detailed in the available content.

So what is it?

Rectangle is a window management app for Mac that lets you quickly arrange and resize windows using keyboard shortcuts or by dragging windows to the edges of your screen. Instead of manually dragging windows around or using your mouse to resize them one pixel at a time, you can snap windows into preset positions with a single keystroke or gesture. The app works in two main ways. First, you can use keyboard shortcuts to instantly move a window to specific positions, like the left half of your screen, a corner, or a third of the screen. Second, you can drag a window toward the edge or corner of your screen, and Rectangle will show you a preview of where it will snap to when you release the mouse. This snap feature works for half-screen layouts, quarters, thirds, and other common window positions. You can turn off snapping if you prefer to stick to keyboard shortcuts. If you spend time switching between multiple applications or frequently need to see two windows side by side, Rectangle saves you from constant manual resizing. Developers, designers, and anyone who works with multiple windows simultaneously would find this useful. You can also customize every keyboard shortcut, ignore specific apps if you don't want Rectangle to affect them, and even trigger window actions through URLs or terminal commands. For power users, the app stores all your settings in a JSON file that you can backup or share across different Macs. Rectangle is free and open source, built in Swift (Apple's programming language), and works on recent versions of macOS. It's lightweight and runs quietly in the background, it won't slow down your Mac or get in the way unless you're actively using a window command.

Copy-paste prompts

Prompt 1
Help me install Rectangle on my Mac and set up keyboard shortcuts for half-screen and quarter-screen window snapping.
Prompt 2
Show me how to customize Rectangle's snap shortcuts and exclude a specific app from being affected.
Prompt 3
Explain how to back up and share my Rectangle settings JSON file across multiple Macs.
Prompt 4
Walk me through triggering a Rectangle window action from a terminal command.
Prompt 5
What edge-drag gestures does Rectangle support for snapping windows into thirds?

Frequently asked questions

What is rectangle?

A free, open-source Mac window manager that snaps windows into halves, quarters, and thirds using keyboard shortcuts or edge-dragging.

What language is rectangle written in?

Mainly Swift. The stack also includes Swift, macOS.

Is rectangle actively maintained?

Dormant — no commits in 2+ years (last push 2023-12-30).

What license does rectangle use?

Free and open source, specific license terms are not detailed in the available content.

How hard is rectangle to set up?

Setup difficulty is rated easy, with roughly 5min to a first successful run.

Who is rectangle for?

Mainly general.

Open on GitHub → Ask about another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.