Inside Ladybird: The Open‑Source Cross‑Platform Browser Built on SerenityOS

Ladybird, an open‑source cross‑platform browser created by SerenityOS author Andreas Kling, evolved from a LibWeb debugging tool into a full GUI browser, leveraging SerenityOS’s LibWeb, LibJS, and Qt, and currently runs on Linux, macOS, Windows (WSL) and Android, though still early‑stage.

Programmer DD
Programmer DD
Programmer DD
Inside Ladybird: The Open‑Source Cross‑Platform Browser Built on SerenityOS

SerenityOS author Andreas Kling recently introduced his open‑source cross‑platform browser project, Ladybird.

Ladybird was born on July 4 this year, initially as a debugging tool for SerenityOS’s “LibWeb” engine; Andreas then added a simple GUI. Two months later the project matured into a full‑featured cross‑platform web browser.

Ladybird browser visual
Ladybird browser visual

Basic Architecture

LibWeb and LibJS are new engines written in C++. The author’s background in Qt and WebKit inspired the design, but all code is original.

The current browser stack can be roughly divided as follows:

Ladybird : tabbed browser GUI application

LibWeb : web engine supporting HTML, DOM, CSS, SVG, …

LibJS : ECMAScript language, runtime library, garbage collector

LibGfx : 2D graphics, text rendering, image formats (PNG, JPG, GIF, …)

LibRegex : regular‑expression engine

LibXML : XML parser

LibWasm : WebAssembly parser and interpreter

LibUnicode : Unicode support library

LibTextCodec : text‑encoding conversion

LibMarkdown : Markdown parser

LibCore : assorted utilities (I/O, date‑time, MIME data, …)

Qt : cross‑platform GUI and networking

LibWeb includes a Platform layer; Ladybird injects Qt support code for the event loop, timers, system‑font settings, etc. Currently Ladybird uses Qt for networking because a multi‑process RequestServer does not exist outside SerenityOS. Ladybird runs as a single process, unlike the SerenityOS browser where each tab runs in its own process.

Completion: Low

Ladybird runs on Linux, macOS, Windows (WSL) and Android, but many networking features are missing or broken, so it is not yet ready for everyday browsing.

It has passed the classic Acid3 test, which covers a range of basic CSS layout features and DOM/HTML APIs.

The Acid3 test, from the Web Standards Project, checks a browser’s compliance with various web standards, especially the DOM and JavaScript.
Acid3 test result
Acid3 test result

However, Acid3 does not cover newer standards such as CSS Flexbox or CSS Grid, leading to layout and compatibility issues—for example, when viewing Reddit in Ladybird.

Reddit page rendering issues in Ladybird
Reddit page rendering issues in Ladybird

The GUI and engine code are released under the BSD‑2‑Clause license and hosted on GitHub: https://github.com/SerenityOS/ladybird.

Original Source

Signed-in readers can open the original source through BestHub's protected redirect.

Sign in to view source
Republication Notice

This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactadmin@besthub.devand we will review it promptly.

Cross-PlatformC++BrowserQtopen-sourceweb engine
Programmer DD
Written by

Programmer DD

A tinkering programmer and author of "Spring Cloud Microservices in Action"

0 followers
Reader feedback

How this landed with the community

Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.