Reduce Gnome's Window Titlebar

Posted on Thu 21 September 2017 in linux

On devices with small screens, such as laptops, you may want to reduce the size of the wide windows title bar in Gnome to save some space. To do so, you can simply add the following content to the ~/.config/gtk-3.0/gtk.css file:

window.ssd headerbar.titlebar {
    padding-top: 5px;
    padding-bottom: 5px;

window.ssd headerbar.titlebar button.titlebutton {
    padding: 0px;
    min-height: 0;
    min-width: 0;

After restarting the gnome session (alt+F2, then enter r and press return) the size of the window's titlebar is reduced correspondingly.