Falco logo

Falco

Tiny browser engine written from scratch in Rust.

RustDeveloper ToolsRustMIT 152 17Health 77
donate MonoBankbuilt with rustbinary ~10 MBLOC ~36,000
GitHub

What is it?

What it is

A tiny, fast browser engine written in Rust that renders HTML, CSS, JavaScript, SVG, and images to either a PNG file or a live interactive window.

Why it exists

To provide a lightweight, high-performance browser engine that is not a wrapper around existing engines like WebKit or Chromium, designed for both standalone use and programmatic embedding in game engines or GUI toolkits.

Who should use it

Game developers looking to embed a lightweight browser engine for UI/HUDGUI toolkit developers needing a rendering componentDevelopers building headless browser tools for PNG snapshotsRust developers interested in studying custom browser engine architecturesEngineers needing a lightweight, low-memory footprint web renderer

Who should avoid it

Users requiring full WebGL/Video/DRM support (currently stubs)Developers needing high-performance asynchronous JS (fetch is currently blocking)Users requiring strict security enforcement (SOP/CSP/Sandbox are implemented but not yet enforced in the renderer)Production-critical applications requiring full WHATWG/W3C spec compliance

How it works

A quick walkthrough in plain English

How Falco works

Step 1 of 3

You interact with it

Open Falco, send a request, or connect it to your stack.

Features

Full HTML, CSS, JavaScript, SVG, and image rendering
Custom JavaScript VM (tjs) with bytecode interpreter and JIT (Linux x86_64)
Interactive window mode with scrolling, forms, and navigation
Headless PNG rendering
Programmatic API for raw RGBA/BGRA/RGB buffer output
Layout engine supporting Flexbox, CSS Grid, Table, and Float
Support for modern CSS selectors (:has, :is, :where)
DOM mutation support via JS-to-DOM bridge
Networking support for HTTP/1.1, WebSockets, and Cookies
Built entirely in Rust from scratch (no WebKit/Chromium dependency)

Advantages

  • Extremely lightweight (~10 MB binary size)
  • High performance due to Rust implementation and JIT tier-up
  • Minimal dependencies (hand-written PNG encoder)
  • Embeddable in game engines (e.g., Bevy, Fyrox) via raw pixel buffers
  • Low CPU usage through incremental repainting in interactive mode

Disadvantages

  • Early stage development (v0.1.0/v0.2.0/v0.3.0 milestones)
  • Many spec-compliant modules (HTML5, DOM, CSS, Security) are implemented but not yet wired into the main renderer
  • JavaScript fetch() is currently blocking rather than truly asynchronous
  • Limited platform support for JIT (Linux x86_64 only)
  • Missing advanced features like CSS animations, transitions, and WebGL/Video rendering

Installation

native

cargo build --release
./target/release/falco page.html --out page.png --width 1200
./target/release/falco https://example.com --out example.png --width 800
./target/release/falco page.html --window
./target/release/falco README.html --css style.css --out readme.png

FAQ

What is Falco and what makes it unique?

Falco is a tiny, fast browser engine written entirely in Rust from scratch. It parses HTML, applies CSS, executes JavaScript, and renders to a PNG or interactive window without relying on existing engines like WebKit or Chromium.

Is Falco production-ready?

No, Falco is in an early stage (v0.1.0) and is not production-ready. Many features are stubs or not yet integrated into the render pipeline.

How do I start using Falco?

You can build Falco with `cargo build --release` and then render HTML files or URLs to PNG using commands like `./falco page.html --out output.png` or open an interactive window with `--window`.

What features does Falco support?

Falco supports HTML5 parsing, CSS3 features (including Flexbox, Grid, and Selectors Level 4), JavaScript (with a custom VM), SVG rendering, image loading, and interactive window mode with forms and navigation.

What are the current limitations of Falco?

Falco lacks features like CSS animations, real DOM mutation from JavaScript, full HTTP/2 support, and security enforcement (SOP, CSP) in the renderer. The spec-compliant parsers are not yet integrated.

Can JavaScript manipulate the DOM in Falco?

Yes, as of v0.2.0, JavaScript can mutate the DOM. Changes made via `innerHTML`, `style`, or DOM methods trigger a re-render, allowing dynamic content updates.

Loading documentation…
View on GitHub

Featured in Videos

YouTube tutorials and walkthroughs for Falco

Alternatives

Similar projects ranked by category, topics, and text overlap.

Compare
Falco | MushyBook