# \[tip & trick\] Picom and @include

**URL:** <https://forum.endeavouros.com/t/tip-trick-picom-and-include/79102>\
**Category:** Applications\
**Created:** [April 12, 2026, 8:37am UTC](https://forum.endeavouros.com/t/tip-trick-picom-and-include/79102 "2026-04-12T08:37:59Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![made-lief](https://forum.endeavouros.com/user_avatar/forum.endeavouros.com/made-lief/32/64412_2.png) [@made-lief](https://forum.endeavouros.com/u/made-lief)\
**Post date:** [April 12, 2026, 8:38am UTC](https://forum.endeavouros.com/t/tip-trick-picom-and-include/79102/1 "2026-04-12T08:38:00Z")

</div>

**Picom supports** @include **for modular config files**

Not sure how many people know this, but picom has an `@include` directive that lets you split your config into separate files per application.

* * *

**The idea**

Instead of stuffing all window rules into one file, picom supports `@include` directives. You keep a lean main config and put per-app rules in separate small files. Easy to read, easy to tweak.

* * *

**The folder structure**

```auto
~/.config/picom/
├── configs/
│ └── mabox-jaskier.conf ← main picom config
└── include/
    ├── mabox-rules.conf ← master rules file
    ├── kitty.conf
    ├── geany.conf
    ├── volbar.conf
    └── ... ← one file per app

```

* * *

**How it works**

**Step 1** — At the bottom of your main picom config, include the rules file:

```auto
@include "mabox-rules.conf";

```

Picom looks for included files relative to the config, or in `~/.config/picom/include/`.

**Step 2** — In `mabox-rules.conf`, you open a `rules:` block and include each app config inside it:

```auto
rules: (
    {
        @include "kitty.conf"
    },
    {
        @include "geany.conf"
    },
)

```

**Step 3** — Each app file contains just its match rule and settings:

```auto
# kitty.conf
match = "class_g = 'kitty'";
blur-background = false;
opacity = 1.0;
dim = 0.0;
animations = (
    {
      triggers = ["open"];
      preset = "fly-in";
      direction = "down";
      duration = 0.5;
    },
)

```

[https://man.archlinux.org/man/picom.1](https://man.archlinux.org/man/picom.1#CONFIGURATION_FILES)

> When @include directive is used in the config file, picom will first search for the included file in the parent directory of picom.conf, then in $XDG\_CONFIG\_HOME/picom/include/, then in $XDG\_CONFIG\_DIRS/picom/include.

This git has examples of configs to get a better idea.

> **[M bird / mabox-picom-config-collection · GitLab](https://gitlab.com/muzlabz/mabox-picom-config-collection)**
>
> GitLab.com

🐧 have fun…
