Dispatchers

Dispatchers

Please keep in mind some layout-specific dispatchers will be listed in the layout pages (See the sidebar).

Parameter explanation

Param typeDescription
windowa window. Any of the following: class regex (by default, optionally class:), initialclass: initial class regex, title: title regex, initialtitle initial title regex, pid: the pid, address: the address, activewindow an active window, floating the first floating window on the current workspace, tiled the first tiled window on the current workspace
workspacesee below.
directionl r u d left right up down
monitorOne of: direction, ID, name, current, relative (e.g. +1 or -1)
resizeparamsrelative pixel delta vec2 (e.g. 10 -10), optionally a percentage of the window size (e.g. 20 25%) or exact followed by an exact vec2 (e.g. exact 1280 720), optionally a percentage of the screen size (e.g. exact 50% 50%)
floatvaluea relative float delta (e.g -0.2 or +0.2) or exact followed by a the exact float value (e.g. exact 0.5)
zheighttop or bottom
modSUPER, SUPER_ALT, etc.
keyg, code:42, 42 or mouse clicks (mouse:272)

List of Dispatchers

DispatcherDescriptionParams
execexecutes a shell commandcommand (supports rules, see below)
execrexecutes a raw shell command (does not support rules)command
passpasses the key (with mods) to a specified window. Can be used as a workaround to global keybinds not working on Wayland.window
sendshortcutsends specified keys (with mods) to an optionally specified window. Can be used like passmod, key[, window]
killactivecloses (not kills) the active windownone
closewindowcloses a specified windowwindow
workspacechanges the workspaceworkspace
movetoworkspacemoves the focused window to a workspaceworkspace OR workspace,window for a specific window
movetoworkspacesilentsame as above, but doesn’t switch to the workspaceworkspace OR workspace,window for a specific window
togglefloatingtoggles the current window’s floating stateleft empty / active for current, or window for a specific window
setfloatingsets the current window’s floating state to trueleft empty / active for current, or window for a specific window
settiledsets the current window’s floating state to falseleft empty / active for current, or window for a specific window
fullscreentoggles the focused window’s fullscreen mode0 - fullscreen (takes your entire screen), 1 - maximize (keeps gaps and bar(s))
fullscreenstatesets the focused window’s fullscreen mode and the one sent to the clientinternal client, where internal and client can be -1 - current, 0 - none, 1 - maximize, 2 - fullscreen, 3 - maximize and fullscreen
dpmssets all monitors’ DPMS status. Do not use with a keybind directly.on, off, or toggle. For specific monitor add monitor name after a space
pinpins a window (i.e. show it on all workspaces) note: floating onlyleft empty / active for current, or window for a specific window
movefocusmoves the focus in a directiondirection
movewindowmoves the active window in a direction or to a monitor. For floating windows, moves the window to the screen edge in that directiondirection or mon: and a monitor, optionally followed by a space and silent to prevent the focus from moving with the window
swapwindowswaps the active window with another window in the given directiondirection
centerwindowcenter the active window note: floating onlynone (for monitor center) or 1 (to respect monitor reserved area)
resizeactiveresizes the active windowresizeparams
moveactivemoves the active windowresizeparams
resizewindowpixelresizes a selected windowresizeparams,window, e.g. 100 100,^(kitty)$
movewindowpixelmoves a selected windowresizeparams,window
cyclenextfocuses the next window on a workspacenone (for next) or prev (for previous) additionally tiled for only tiled, floating for only floating. prev tiled is ok.
swapnextswaps the focused window with the next window on a workspacenone (for next) or prev (for previous)
tagwindowapply tag to current or the first window matchingtag [window], e.g. +code ^(foot)$, music
focuswindowfocuses the first window matchingwindow
focusmonitorfocuses a monitormonitor
splitratiochanges the split ratiofloatvalue
movecursortocornermoves the cursor to the corner of the active windowdirection, 0 - 3, bottom left - 0, bottom right - 1, top right - 2, top left - 3
movecursormoves the cursor to a specified positionx y
renameworkspacerename a workspaceid name, e.g. 2 work
exitexits the compositor with no questions asked.none
forcerendererreloadforces the renderer to reload all resources and outputsnone
movecurrentworkspacetomonitorMoves the active workspace to a monitormonitor
focusworkspaceoncurrentmonitorFocuses the requested workspace on the current monitor, swapping the current workspace to a different monitor if necessary. If you want XMonad/Qtile-style workspace switching, replace workspace in your config with this.workspace
moveworkspacetomonitorMoves a workspace to a monitorworkspace and a monitor separated by a space
swapactiveworkspacesSwaps the active workspaces between two monitorstwo monitors separated by a space
bringactivetotopDeprecated in favor of alterzorder. Brings the current window to the top of the stacknone
alterzorderModify the window stack order of the active or specified window. Note: this cannot be used to move a floating window behind a tiled one.zheight[,window]
togglespecialworkspacetoggles a special workspace on/offnone (for the first) or name for named (name has to be a special workspace’s name)
focusurgentorlastFocuses the urgent window or the last windownone
togglegrouptoggles the current active window into a groupnone
changegroupactiveswitches to the next window in a group.b - back, f - forward, or index start at 1
focuscurrentorlastSwitch focus from current to previously focused windownone
lockgroupsLocks the groups (all groups will not accept new windows)lock for locking, unlock for unlocking, toggle for toggle
lockactivegroupLock the focused group (the current group will not accept new windows or be moved to other groups)lock for locking, unlock for unlocking, toggle for toggle
moveintogroupMoves the active window into a group in a specified direction. No-op if there is no group in the specified direction.direction
moveoutofgroupMoves the active window out of a group. No-op if not in a groupleft empty / active for current, or window for a specific window
movewindoworgroupBehaves as moveintogroup if there is a group in the given direction. Behaves as moveoutofgroup if there is no group in the given direction relative to the active group. Otherwise behaves like movewindow.direction
movegroupwindowSwaps the active window with the next or previous in a groupb for back, anything else for forward
denywindowfromgroupProhibit the active window from becoming or being inserted into groupon, off or, toggle
setignoregrouplockTemporarily enable or disable binds:ignore_group_lockon, off, or toggle
globalExecutes a Global Shortcut using the GlobalShortcuts portal. See herename
submapChange the current mapping group. See Submapsreset or name
eventEmits a custom event to socket2 in the form of custom>>yourdatathe data to send
setpropSets a window propertywindow property value
⚠️

uwsm users should avoid using exit dispatcher, or terminating Hyprland process directly, as exiting Hyprland this way removes it from under its clients and interferes with ordered shutdown sequence. Use exec, uwsm stop (or other variants) which will gracefully bring down graphical session (and login session bound to it, if any). If you experience problems with units entering inconsistent states, affecting subsequent sessions, use exec, loginctl terminate-user "" instead (terminates all units of the user).

It’s also strongly advised to replace the exit dispatcher inside hyprland.conf keybinds section accordingly.

⚠️

It is NOT recommended to set DPMS with a keybind directly, as it might cause undefined behavior. Instead, consider something like

bind = MOD, KEY, exec, sleep 1 && hyprctl dispatch dpms off

Grouped (tabbed) windows

Hyprland allows you to make a group from the current active window with the togglegroup bind dispatcher.

A group is like i3wm’s “tabbed” container. It takes the space of one window, and you can change the window to the next one in the tabbed “group” with the changegroupactive bind dispatcher.

The new group’s border colors are configurable with the appropriate col. settings in the group config section.

You can lock a group with the lockactivegroup dispatcher in order to stop new windows from entering this group. In addition, the lockgroups dispatcher can be used to toggle an independent global group lock that will prevent new windows from entering any groups, regardless of their local group lock stat.

You can prevent a window from being added to a group or becoming a group with the denywindowfromgroup dispatcher. movewindoworgroup will behave like movewindow if the current active window or window in direction has this property set.

Workspaces

You have nine choices:

  • ID: e.g. 1, 2, or 3

  • Relative ID: e.g. +1, -3 or +100

  • workspace on monitor, relative with + or -, absolute with ~: e.g. m+1, m-2 or m~3

  • workspace on monitor including empty workspaces, relative with + or -, absolute with ~: e.g. r+1 or r~3

  • open workspace, relative with + or -, absolute with ~: e.g. e+1, e-10, or e~2

  • Name: e.g. name:Web, name:Anime or name:Better anime

  • Previous workspace: previous, or previous_per_monitor

  • First available empty workspace: empty, suffix with m to only search on monitor. and/or n to make it the next available empty workspace. e.g. emptynm

  • Special Workspace: special or special:name for named special workspaces.

⚠️
special is supported ONLY on movetoworkspace and movetoworkspacesilent. Any other dispatcher will result in undocumented behavior.

Numerical workspaces (e.g. 1, 2, 13371337) are allowed ONLY between 1 and 2147483647 (inclusive)

Neither 0 nor negative numbers are allowed.

Special Workspace

A special workspace is what is called a “scratchpad” in some other places. A workspace that you can toggle on/off on any monitor.

ℹ️
You can define multiple named special workspaces, but the amount of those is limited to 97 at a time.

For example, to move a window/application to a special workspace you can use the following syntax:

bind = SUPER, C, movetoworkspace, special
#The above syntax will move the window to a special workspace upon pressing 'SUPER'+'C'.
#To see the hidden window you can use the togglespecialworkspace dispatcher mentioned above.

Executing with rules

The exec dispatcher supports adding rules. Please note some windows might work better, some worse. It records the PID of the spawned process and uses that. For example, if your process forks and then the fork opens a window, this will not work.

The syntax is:

bind = mod, key, exec, [rules...] command

For example:

bind = SUPER, E, exec, [workspace 2 silent; float; move 0 0] kitty

setprop

Prop List:

propcomment
alphafloat 0.0 - 1.0
alphaoverride0/1, makes the next setting be override instead of multiply
alphainactivefloat 0.0 - 1.0
alphainactiveoverride0/1, makes the next setting be override instead of multiply
alphafullscreenfloat 0.0 - 1.0
alphafullscreenoverride0/1, makes the next setting be override instead of multiply
animationstylestring, cannot be locked
activebordercolorgradient, -1 means not set
inactivebordercolorgradient, -1 means not set
maxsizevec2 (x y)
minsizevec2 (x y)

Additional properties can be found in the Window Rules section.

For example:

address:0x13371337 noanim 1
address:0x13371337 nomaxsize 0
address:0x13371337 opaque toggle
address:0x13371337 immediate unset