Skip to main content
MangoWCMangoWC
Window Management

Rules

Define behavior for specific windows, tags, and layers.

Window Rules

Window rules allow you to set specific properties (floating, opacity, size) for applications based on their appid or title.

Format:

windowrule=Parameter:Value,Parameter:Value,appid:Regex,title:Regex

State Parameters

ParameterValuesDescription
isfloating0 / 1Force the window to float.
isfullscreen0 / 1Open in fullscreen mode.
isglobal0 / 1Pin window to all tags (sticky).
isoverlay0 / 1Render window on top of everything (overlay layer).
isopensilent0 / 1Open window without stealing focus.
istagsilent0 / 1Don't focus if the window opens on a hidden tag.
force_maximize0 / 1Force the window to start maximized.
force_tile_state0 / 1Force the window to tile, even if it requests floating.
noopenmaximized0 / 1Prevent the window from opening in maximized mode.

Geometry & Position

ParameterExampleDescription
width800Set width for floating windows.
height600Set height for floating windows.
offsetx10Horizontal offset from center (percentage -100 to 100).
offsety-10Vertical offset from center.
monitoreDP-1Send to a specific monitor.
tags1Send to a specific tag ID.
no_force_center1Disable auto-centering for floating windows.

Visuals & Decoration

ParameterValuesDescription
noblur0 / 1Disable blur for this window.
isnoborder0 / 1Remove window borders.
isnoshadow0 / 1Disable window shadows.
isnoanimation0 / 1Disable animations for this window.
focused_opacity0.0-1.0Override focused opacity.
unfocused_opacity0.0-1.0Override unfocused opacity.

Advanced

ParameterDescription
globalkeybindingBind a global hotkey (Wayland apps only). Format: mod+key.
isterm1 marks the window as a terminal (useful for swallowing).
noswallow1 prevents this window from being swallowed.
force_tearing1 forces tearing (VSync off) for games.
isnamedscratchpad1 marks this window as a named scratchpad target.
scroller_proportionSet scroller proportion (0.1-1.0).
animation_type_openSet open animation (zoom, slide, fade, none).
animation_type_closeSet close animation (zoom, slide, fade, none).
isnosizehint1 disables size hints from client.
isunglobal1 makes it an unmanaged global window.
nofadein1 ignores fade-in animation.
allow_csd1 allows client-side decoration.
allow_shortcuts_inhibit1 allows shortcuts to be inhibited by clients.

Examples

# Center a music player and set size
windowrule=width:1000,height:900,isfloating:1,appid:yesplaymusic

# Set a global toggle key for OBS
windowrule=globalkeybinding:ctrl+alt-o,appid:com.obsproject.Studio

# Open Discord on tag 9
windowrule=tags:9,appid:discord

# Force CS2 to allow tearing
windowrule=force_tearing:1,title:Counter-Strike 2

# Create a named scratchpad for file manager
windowrule=isnamedscratchpad:1,width:1280,height:800,appid:st-yazi

Tag Rules

Configure default layouts and behaviors for specific tags.

Format:

tagrule=id:Number,Parameter:Value
ParameterTypeValuesDescription
idinteger0-9Match by tags id, 0 means ~0 tag
monitor_namestringmonitor nameMatch by monitor name
layout_namestringlayout nameLayout name to set, see Supported Layouts for a list.
no_render_borderinteger0 / 1Disable render border
no_hideinteger0 / 1Not hide even if the tag is empty (persistent tag)

Examples

# Persistent tags (1-4)
tagrule=id:1,no_hide:1
tagrule=id:2,no_hide:1
tagrule=id:3,monitor_name:eDP-1,no_hide:1
tagrule=id:4,monitor_name:eDP-1,no_hide:1

# Layout assignments
tagrule=id:1,layout_name:tile
tagrule=id:2,layout_name:scroller
tagrule=id:9,monitor_name:HDMI-A-1,layout_name:monocle

Layer Rules

Target "layer shell" surfaces like status bars (waybar), launchers (rofi), or notification daemons.

Format:

layerrule=layer_name:Regex,Parameter:Value
ParameterTypeValuesDescription
layer_namestringlayer_nameMatch name of layer, support regex
animation_type_openstringslide, zoom, fade, noneSet open animation
animation_type_closestringslide, zoom, fade, noneSet close animation
noblurinteger0 / 1Disable blur
noaniminteger0 / 1Disable layer animation
noshadowinteger0 / 1Disable layer shadow

Examples:

# Zoom animation for Rofi
layerrule=animation_type_open:zoom,layer_name:rofi

# Disable blur for screenshot selection tool
layerrule=noblur:1,layer_name:selection

# Disable animations for notification daemon
layerrule=noanim:1,layer_name:swaync

On this page