2024-02-20 22:16:07 +02:00
---
weight: 2
title: Status bars
---
2023-04-18 00:41:26 +01:00
2025-09-09 02:19:19 -07:00
## Simple status bars
2025-05-31 13:27:08 +02:00
Typically you'll be able to configure the order and style of widgets with little to no coding skill.
2025-09-09 02:19:19 -07:00
### Waybar
2022-08-12 20:46:36 +02:00
2023-09-05 11:39:20 +00:00
Waybar is a GTK status bar made specifically for wlroots compositors and
supports Hyprland by default. To use it, it's recommended to use your distro's
package.
2022-10-23 17:35:39 +03:00
2024-07-31 01:00:24 +03:00
To start configuring, copy the configuration files from
2025-02-17 17:40:09 +01:00
`/etc/xdg/waybar/` into `~/.config/waybar/` .
2024-07-31 01:00:24 +03:00
To use the workspaces module, replace all the occurrences of `sway/workspaces`
2025-09-14 17:55:02 +01:00
with `hyprland/workspaces` . Additionally replace all occurrences of `sway/mode` with `hyprland/submap`
2022-08-12 20:46:36 +02:00
2022-08-13 02:47:48 +03:00
For more info regarding configuration, see
2023-09-05 11:39:20 +00:00
[The Waybar Wiki ](https://github.com/Alexays/Waybar/wiki/Module:-Hyprland ).
2022-08-12 20:46:36 +02:00
2025-09-09 02:19:19 -07:00
#### How to launch
2023-04-30 03:09:45 +03:00
2024-07-31 01:00:24 +03:00
Type `waybar` into your terminal. In order to have Waybar launch alongside
Hyprland, add this line to your Hyprland configuration:
```ini
exec-once = waybar
```
2024-11-11 23:31:46 +05:00
Waybar also provides a systemd service. If you use Hyprland with [uwsm ](../../Useful-Utilities/Systemd-start ), you can enable it, using the following command.
2024-11-11 19:53:20 +05:00
```ini
systemctl --user enable --now waybar.service
```
2025-09-09 02:19:19 -07:00
#### Waybar FAQ
2023-04-30 03:09:45 +03:00
2025-09-09 02:19:19 -07:00
##### Active workspace doesn't show up
2022-10-23 17:36:09 +03:00
2024-02-20 22:16:07 +02:00
Replace `#workspaces button.focused` with `#workspaces button.active` in
`~/.config/waybar/style.css` .
2022-10-23 17:36:09 +03:00
2025-09-09 02:19:19 -07:00
##### Scrolling through workspaces
2022-10-23 17:36:09 +03:00
2024-04-21 10:35:48 -04:00
Since a lot of configuration options from `sway/workspaces` are missing,
2024-02-20 22:16:07 +02:00
you should deduce some of them by yourself. In the case of scrolling, it should
look like this:
2022-10-23 17:36:09 +03:00
```json
2023-09-05 11:39:20 +00:00
"hyprland/workspaces": {
2022-10-23 17:36:09 +03:00
"format": "{icon}",
"on-scroll-up": "hyprctl dispatch workspace e+1",
"on-scroll-down": "hyprctl dispatch workspace e-1"
}
```
2025-09-09 02:19:19 -07:00
#### Window title is missing
2022-10-23 17:36:09 +03:00
2024-08-04 11:49:21 +02:00
The prefix for the window module that provides the title is `hyprland` not `wlr` .
In your Waybar config, insert this module:
2023-05-23 08:08:20 -04:00
```json
"modules-center": ["hyprland/window"],
```
2024-02-20 22:16:07 +02:00
2024-08-04 11:49:21 +02:00
If you are using multiple monitors, you may want to insert the following option:
2024-02-20 22:16:07 +02:00
2023-05-23 08:08:20 -04:00
```json
"hyprland/window": {
"separate-outputs": true
},
```
2025-10-14 00:05:47 +04:00
### ashell
[ashell ](https://malpenzibo.github.io/ashell/ ) is a ready to go Wayland status bar for Hyprland
- Ashell is ready to use out of the box. Just install it, start using it, and customize only what you need.
- Ashell comes with essential modules like workspaces, time, battery, network, and more. No need to hunt for plugins or write custom scripts.
- Powered by iced. A cross-platform GUI library for Rust
- Has a pretty limited configuration options. It's a good and a bad thing at the same time. You can get a very decent result quickly and with a little effort, but some tricky waybar-alike tweaks are not possible.
- Calendar is absent but in the [roadmap ](https://github.com/MalpenZibo/ashell/issues/181 )
#### Workaround for calendar
```toml
[modules]
center = [ "calendar", "Clock" ]
# ...
[[CustomModule]]
name = "calendar"
icon = ""
command = "zenity --calendar --title=\"Calendar\""
```
2025-09-09 02:19:19 -07:00
## Widget systems
2025-05-31 13:27:08 +02:00
Use them when you want custom menus with fully customizable layout.
You basically need to write code, but widget systems significantly
ease the process.
Below are three popular choices in alphabetical order.
| | [AGS/Astal ](https://aylur.github.io/astal/ ) | [EWW ](https://elkowar.github.io/eww/ ) | [Quickshell ](https://quickshell.outfoxxed.me/ ) |
|--------------------------|-------------------|-------------------|-------------------|
| UI Toolkit | GTK 3/4 | GTK 3 | Qt |
| Config language | JS(X)/TS/languages that support [Gobject Introspection ](https://en.wikipedia.org/wiki/List_of_language_bindings_for_GTK ) | Yuck (EWW's flavor of Lisp) | QML |
2025-09-09 02:19:19 -07:00
### AGS/Astal
2025-05-31 13:27:08 +02:00
- [Astal ](https://aylur.github.io/astal/ ) is a suite and framework to craft desktop shells and Wayland widgets with GTK.
- [AGS ](https://aylur.github.io/ags/ ) (Aylur's GTK Shell) is a scaffolding tool for Astal and TypeScript/Javascript(X).
In simple words, it eases creation of Astal projects in those languages.
2025-07-08 21:29:40 +02:00
To get started with Astal, see its [installation instructions ](https://aylur.github.io/astal/guide/installation )
and [examples ](https://aylur.github.io/astal/guide/introduction#supported-languages ).
2025-05-31 13:27:08 +02:00
For AGS, see its [Quick start ](https://aylur.github.io/ags/guide/quick-start.html ) page.
2025-09-09 02:19:19 -07:00
#### Advantages
2025-05-31 13:27:08 +02:00
- Language flexibility: You can use your favorite if it supports
[Gobject Introspection ](https://en.wikipedia.org/wiki/List_of_language_bindings_for_GTK ) (although JS(X)/TS are most well-supported by AGS)
- Provides a large set of libraries, including Network (both Wi-Fi and Ethernet) and Bluetooth
2025-09-09 02:19:19 -07:00
#### Disadvantages
2025-05-31 13:27:08 +02:00
- Does not provide hot reload out of the box
2023-05-23 08:08:20 -04:00
2025-09-09 02:19:19 -07:00
### Eww
2022-08-12 20:46:36 +02:00
2024-07-31 01:00:24 +03:00
[Eww ](https://github.com/elkowar/eww ) (ElKowar's Wacky Widgets) is a widget
2024-11-06 17:28:13 +00:00
system made in Rust + GTK, which allows the creation of custom widgets
2024-07-31 01:00:24 +03:00
similarly to AwesomeWM. The key difference is that it is independent of window
manager/compositor.
2024-06-25 14:17:51 -05:00
2024-07-31 01:00:24 +03:00
Install Eww either using your distro's package manager, by searching
`eww-wayland` , or by manually compiling. In the latter case, you can follow the
2022-08-13 19:25:43 +03:00
[instructions ](https://elkowar.github.io/eww ).
2022-08-12 20:46:36 +02:00
2025-09-09 02:19:19 -07:00
#### Advantages
2025-05-31 13:27:08 +02:00
- Its Lisp-like config syntax is simple compared to other config languages
- Supports styling with SCSS out of the box
2025-09-09 02:19:19 -07:00
#### Disadvantages
2025-05-31 13:27:08 +02:00
- Heavy reliance on external scripts/programs, as it does not provide many libraries
- Performance
- Only supports GTK 3, which does not support GPU acceleration
- Overhead from the use of external scripts and unnecessary component recreations on data re-evaluation
2025-09-09 02:19:19 -07:00
#### Configuration
2022-08-12 20:46:36 +02:00
2024-07-31 01:00:24 +03:00
There are a few examples listed in the [Readme ](https://github.com/elkowar/eww ).
It's also highly recommended to read through the
2022-08-12 20:46:36 +02:00
[Configuration options ](https://elkowar.github.io/eww/configuration.html ).
2024-02-20 22:16:07 +02:00
{{< callout > }}
2022-08-13 19:25:43 +03:00
Read
[the Wayland section ](https://elkowar.github.io/eww/configuration.html#wayland )
2024-07-31 01:00:24 +03:00
carefully, otherwise Eww won't work on Hyprland.
2024-02-20 22:16:07 +02:00
{{< / callout > }}
2022-10-23 17:36:09 +03:00
2022-12-17 15:43:14 -07:00
Here are some example widgets that might be useful for Hyprland:
< details >
< summary > Workspaces widget< / summary >
2024-02-20 22:16:07 +02:00
This widget displays a list of workspaces 1-10. Each workspace can be clicked on
to jump to it, and scrolling over the widget cycles through them. It supports
different styles for the current workspace, occupied workspaces, and empty
workspaces. It requires [bash ](https://linux.die.net/man/1/bash ),
[awk ](https://linux.die.net/man/1/awk ),
[stdbuf ](https://linux.die.net/man/1/stdbuf ),
[grep ](https://linux.die.net/man/1/grep ),
[seq ](https://linux.die.net/man/1/seq ),
[socat ](https://linux.die.net/man/1/socat ),
[jq ](https://stedolan.github.io/jq/ ), and [Python 3 ](https://www.python.org/ ).
2022-12-17 15:43:14 -07:00
2025-09-09 02:19:19 -07:00
##### `~/.config/eww.yuck`
2022-12-17 15:43:14 -07:00
```lisp
...
(deflisten workspaces :initial "[]" "bash ~/.config/eww/scripts/get-workspaces")
(deflisten current_workspace :initial "1" "bash ~/.config/eww/scripts/get-active-workspace")
(defwidget workspaces []
(eventbox :onscroll "bash ~/.config/eww/scripts/change-active-workspace {} ${current_workspace}" :class "workspaces-widget"
(box :space-evenly true
2023-03-04 15:49:21 +01:00
(label :text "${workspaces}${current_workspace}" :visible false)
2022-12-17 15:43:14 -07:00
(for workspace in workspaces
(eventbox :onclick "hyprctl dispatch workspace ${workspace.id}"
2024-09-14 05:22:59 -06:00
(box :class "workspace-entry ${workspace.windows > 0 ? "occupied" : "empty"}"
(label :text "${workspace.id}" :class "workspace-entry ${workspace.id == current_workspace ? "current" : ""}" )
2022-12-17 15:43:14 -07:00
)
)
)
)
)
)
...
```
2025-09-09 02:19:19 -07:00
##### `~/.config/eww/scripts/change-active-workspace`
2022-12-17 15:43:14 -07:00
```sh
2024-03-07 18:38:37 -05:00
#!/usr/bin/env bash
2022-12-17 15:43:14 -07:00
function clamp {
2024-11-06 20:34:37 +02:00
min=$1
max=$2
val=$3
python -c "print(max($min, min($val, $max)))"
2022-12-17 15:43:14 -07:00
}
direction=$1
current=$2
if test "$direction" = "down"
then
2024-11-06 20:34:37 +02:00
target=$(clamp 1 10 $(($current+1)))
echo "jumping to $target"
hyprctl dispatch workspace $target
2022-12-17 15:43:14 -07:00
elif test "$direction" = "up"
then
2024-11-06 20:34:37 +02:00
target=$(clamp 1 10 $(($current-1)))
echo "jumping to $target"
hyprctl dispatch workspace $target
2022-12-17 15:43:14 -07:00
fi
```
2025-09-09 02:19:19 -07:00
##### `~/.config/eww/scripts/get-active-workspace`
2022-12-17 15:43:14 -07:00
```sh
2023-05-18 17:31:58 +02:00
#!/usr/bin/env bash
hyprctl monitors -j | jq '.[] | select(.focused) | .activeWorkspace.id'
2024-04-28 22:25:40 +01:00
socat -u UNIX-CONNECT:$XDG_RUNTIME_DIR/hypr/$HYPRLAND_INSTANCE_SIGNATURE/.socket2.sock - |
2023-05-18 17:31:58 +02:00
stdbuf -o0 awk -F '>>|,' -e '/^workspace>>/ {print $2}' -e '/^focusedmon>>/ {print $3}'
2022-12-17 15:43:14 -07:00
```
2025-09-09 02:19:19 -07:00
##### `~/.config/eww/scripts/get-workspaces`
2022-12-17 15:43:14 -07:00
```sh
2024-03-07 18:38:37 -05:00
#!/usr/bin/env bash
2022-12-17 15:43:14 -07:00
spaces (){
2024-11-06 20:34:37 +02:00
WORKSPACE_WINDOWS=$(hyprctl workspaces -j | jq 'map({key: .id | tostring, value: .windows}) | from_entries')
seq 1 10 | jq --argjson windows "${WORKSPACE_WINDOWS}" --slurp -Mc 'map(tostring) | map({id: ., windows: ($windows[.]//0)})'
2022-12-17 15:43:14 -07:00
}
spaces
2024-04-28 22:25:40 +01:00
socat -u UNIX-CONNECT:$XDG_RUNTIME_DIR/hypr/$HYPRLAND_INSTANCE_SIGNATURE/.socket2.sock - | while read -r line; do
2024-11-06 20:34:37 +02:00
spaces
2022-12-17 15:43:14 -07:00
done
```
< / details >
< details >
< summary > Active window title widget< / summary >
2024-02-20 22:16:07 +02:00
This widget simply displays the title of the active window. It requires
[awk ](https://linux.die.net/man/1/awk ),
[stdbuf ](https://linux.die.net/man/1/stdbuf ),
[socat ](https://linux.die.net/man/1/socat ), and
[jq ](https://stedolan.github.io/jq/ ).
2022-12-17 15:43:14 -07:00
2025-09-09 02:19:19 -07:00
##### `~/.config/eww/eww.yuck`
2022-12-17 15:43:14 -07:00
```lisp
...
2023-04-23 22:20:55 +02:00
(deflisten window :initial "..." "sh ~/.config/eww/scripts/get-window-title")
2022-12-17 15:43:14 -07:00
(defwidget window_w []
(box
(label :text "${window}"
)
)
...
```
2025-09-09 02:19:19 -07:00
##### `~/.config/eww/scripts/get-window-title`
2022-12-17 15:43:14 -07:00
```sh
2023-04-23 22:20:55 +02:00
#!/bin/sh
2022-12-17 15:43:14 -07:00
hyprctl activewindow -j | jq --raw-output .title
2024-04-28 22:25:40 +01:00
socat -u UNIX-CONNECT:$XDG_RUNTIME_DIR/hypr/$HYPRLAND_INSTANCE_SIGNATURE/.socket2.sock - | stdbuf -o0 awk -F '>>|,' '/^activewindow>>/{print $3}'
2022-12-17 15:43:14 -07:00
```
< / details >
2025-09-09 02:19:19 -07:00
### Quickshell
2025-05-31 13:27:08 +02:00
[Quickshell ](https://quickshell.outfoxxed.me/ ) is a flexbile QtQuick-based desktop shell toolkit.
Note that although Qt is notoriously hard to theme, Quickshell can be styled independently.
To get started, see the
[setup instructions ](https://quickshell.outfoxxed.me/docs/configuration/getting-started/ )
and a [guided hello world ](https://quickshell.outfoxxed.me/docs/configuration/intro/ )
2025-09-09 02:19:19 -07:00
#### Advantages
2025-05-31 13:27:08 +02:00
- Provides advanced Wayland/Hyprland integrations, for example live window previews
- Automatically reloads config on changes out of the box
2025-09-09 02:19:19 -07:00
#### Disadvantages
2025-05-31 13:27:08 +02:00
- Qt can be less intuitive to work with compared to GTK for its positioning system
2025-09-07 06:53:09 -07:00
- Does not yet provide a Wi-Fi service at the time of writing
2025-05-31 13:27:08 +02:00
- It is still in alpha and minor breaking changes are to be expected
- Styles are declared with components instead of in CSS, which might be less familiar for some people
2025-09-09 02:19:19 -07:00
## Tips
2025-05-31 13:27:08 +02:00
2025-09-09 02:19:19 -07:00
### Blur
2025-05-31 13:27:08 +02:00
2025-10-29 13:33:41 +02:00
Use the `blur` and `ignorealpha` [layer rules ](https://wiki.hypr.land/Configuring/Window-Rules/#layer-rules ).
2025-05-31 13:27:08 +02:00
The former enables blur, and the latter makes it ignore insufficiently opaque regions.
Ideally, the value used with `ignorealpha` is higher than the shadow opacity and lower than the bar/menu content's opacity.
Additionally, if it has transparent popups, you can use the `blurpopups` rule.
2023-04-30 03:09:45 +03:00