Title bar

On this page 7

A title bar is the horizontal strip along the top edge of an application window that displays the window title and hosts the window controls for minimizing, maximizing and closing it. In desktop environments, it is also the primary drag handle for moving a window and a frequent target for gestures such as double-clicking to maximize, which makes it one of the most heavily used surfaces in desktop software.

The title bar belongs to the window decoration, the frame that surrounds application content. Depending on the platform, that frame is drawn either by the window manager or compositor on behalf of the application, or by the application itself through its GUI toolkit. This split explains most of the visual and behavioral differences users notice between systems.

How a title bar works

A title bar works by giving the window manager a non-client area where it can interpret pointer input as window operations rather than passing it to the application. A press and drag on the bar starts an interactive move, a press on a button triggers a state change such as minimize or maximize, and a right-click usually opens the window menu with options such as move, resize, always on top and close.

The displayed text comes from a window property that the application sets. On X11 this is the _NET_WM_NAME property defined by the Extended Window Manager Hints specification, on Wayland it is the set_title request of the xdg_toplevel interface, and on Windows it is the text passed to SetWindowText. Applications commonly update the title to show the active document name, an unsaved-changes marker or the current web page.

The following table lists the standard parts of a title bar and the role each plays.

ElementTypical positionFunction
Window titleCenter or leftIdentifies the application or document
Application iconFar left on Windows and many Linux themesOpens the window menu; aids recognition
Minimize buttonRight group or left groupHides the window to the taskbar or dock
Maximize buttonRight group or left groupToggles between full work area and restored size
Close buttonOutermost position in the button groupRequests that the application close the window
Empty drag areaAll remaining spaceMoves the window; double-click toggles maximize
Standard elements of a title bar

Server-side and client-side decorations

The central architectural question is who draws the title bar. With server-side decorations (SSD), the window manager or compositor paints the frame and handles its input, so every window looks consistent regardless of toolkit. With client-side decorations (CSD), the application draws its own title bar inside its surface and tells the compositor which regions behave as drag areas or buttons.

On Wayland, the optional xdg-decoration protocol lets a client and compositor negotiate the decoration mode. GNOME relies on client-side decorations, whereas KDE Plasma prefers server-side decorations and supports both. Windows draws a system frame by default but allows applications to extend content into the caption area, and macOS lets applications use a transparent or unified title bar while the system still supplies the traffic-light buttons.

This table compares the two approaches on the factors that matter most in practice.

FactorServer-side decorationsClient-side decorations
Visual consistencyUniform across all applicationsVaries by toolkit and application
Use of vertical spaceFixed bar height, often 24 to 32 pixelsCan merge title bar and toolbar
Responsiveness when the application hangsBar stays movable and closableBar may freeze with the application
Custom content in the barLimited to title and buttonsTabs, search fields, menus allowed
Implementation effortHandled once by the window managerEach toolkit must implement it
Comparison of decoration approaches

Header bars and other title bar variants

Modern interfaces increasingly replace the classic title bar with a combined header area that carries both window controls and application commands. GTK calls this a header bar, Windows applications build similar layouts with custom title bars, and web browsers place tabs directly in the title bar to reclaim vertical space on wide, short displays.

The variants below show how platforms and applications have adapted the concept.

VariantWhere it appearsKey characteristic
Classic title barTraditional window managers, older applicationsTitle text and buttons only
Header barGTK and GNOME applicationsButtons, title and toolbar actions in one strip
Unified toolbarmacOS applicationsToolbar blends into the title area
Tabbed title barWeb browsers, terminals, file managersTabs occupy the drag area
Tool window barPalettes and floating panelsThinner bar with fewer buttons
Common title bar variants

Button placement is also a variant in itself. Windows and most Linux defaults put the controls on the right side, while macOS places them on the left side in close, minimize and zoom order. Many desktop environments let users move buttons or remove the minimize and maximize controls entirely.

The title bar is one element within a larger set of window management features, and it is often confused with neighbors that share screen space or behavior. Window snapping, for example, is commonly triggered by dragging the title bar to a screen edge, yet snapping itself is a window manager function rather than a property of the bar.

  • The menu bar holds application commands; on macOS it sits at the top of the screen, separate from each window title bar.
  • The taskbar or panel shows open windows using the same title text, so a descriptive title improves task switching.
  • The window border handles resizing, while the title bar handles moving; on CSD systems the resize area may be an invisible margin.
  • The status bar at the bottom of a window shows application state and has no window management role.

Design guidelines and common problems

Good title bar design balances identification, control and space. The title should lead with the most specific information, typically the document name before the application name, so that truncated titles in the taskbar and task switcher remain meaningful. Buttons need adequate hit targets, and the drag area must stay large enough to grab even when tabs or search fields are added.

The table below pairs frequent problems with their causes and remedies.

SymptomLikely causeRemedy
Two stacked title barsBoth compositor and client draw decorationsNegotiate one mode through xdg-decoration
No title bar at allClient expects SSD but compositor provides noneEnable a decoration fallback in the toolkit
Window cannot be draggedCustom bar lacks defined drag regionsMark empty areas as draggable
Frozen bar during a hangClient-side drawing blocked by busy main threadUse compositor ping and force-quit dialogs
Unreadable title textTheme contrast too low in inactive stateMeet WCAG contrast ratios for both states
Title bar problems and fixes

Accessibility deserves explicit attention. Screen readers announce the window title when focus changes, so a precise, unique title directly affects navigation for blind users. Keyboard alternatives such as Alt+F4, Alt+Space and platform maximize shortcuts must remain available even when an application replaces the system bar with its own.

The short version

The title bar is the strip across the top of every window. It tells you which program or document you are looking at. It also gives you three small buttons. One shrinks the window away, one makes it fill the screen, and one closes it.

It is also the handle you grab to move the window around. Think of it as the label and handle on a folder. The label says what is inside. The handle lets you carry the folder elsewhere on the desk.

Where it makes a difference

A support team at a mid-sized company runs a Linux desktop on Wayland with a mix of GTK and Qt applications. After an upgrade, several Qt tools start appearing with no title bar at all, because the compositor in use does not draw server-side decorations and the toolkit was not configured to draw its own. Staff cannot drag those windows between their two monitors and must rely on keyboard shortcuts.

The administrator enables the toolkit decoration plugin so that the affected applications draw client-side title bars, and confirms that the compositor and clients now agree on a single decoration mode. Windows regain their drag handles and buttons, double-click maximize works again, and help-desk tickets about stuck windows drop to zero within a day. The team also adopts a convention of putting the customer case number first in each tool window title, which makes taskbar entries easier to tell apart.