# Box2D

> 2D physics engine for games, written in portable C

Source: https://talira.ai/catalog/box2d-7rkgsyjj
Every listing: https://talira.ai/catalog.md

- Kind: Open source
- Types: Library
- Categories: [libraries / physics engines](https://talira.ai/categories/libraries/physics-engines), [languages / c cpp](https://talira.ai/categories/languages/c-cpp)
- Platforms: windows, linux, macos[^2]
- Licence: MIT[^1]
- Pricing: Free and open source[^1]
- Free tier: yes[^1]
- Backed by: [Erin Catto](https://talira.ai/orgs/erin-catto.md)

Box2D is Erin Catto's 2D rigid body physics engine for games. It handles collision (convex polygons, capsules, circles, rounded polygons, segments and chains, with continuous collision detection, contact and sensor events, ray and shape casts) and physics with its Soft Step solver, joints with limits, motors and springs, island-based sleeping and character movers. Version 3 is written in portable C17 with a data-oriented design, multithreading and SIMD, optional double precision for large worlds, cross-platform determinism, snapshots and recording and replay. It builds with CMake on Windows, Linux and macOS, and can be added from Zig or Swift Package Manager.

## Links

- Website: https://box2d.org/
- GitHub: https://github.com/erincatto/box2d
- Docs: https://box2d.org/documentation/

## Problems it solves

- add realistic 2D physics and collisions to my game
- simulate stacks of rigid bodies with joints in a 2D game engine
- get deterministic 2D physics that replays the same on every platform for multiplayer

## Features

- Continuous collision detection for convex polygons, capsules, circles, segments and chains
- Soft Step rigid body solver with island-based sleep
- Revolute, prismatic, distance, motor, weld and wheel joints with limits, motors and springs
- Character movers with a robust plane solver
- Multithreading, SIMD and optional double precision for large worlds
- Cross-platform determinism, snapshots and recording and replay

## Trust

Overall: 0.59 out of 1.
Signals: maintenance 0.78, adoption 0.80, momentum 0.57, community 0.54, backing 0.30, extensibility 0.00.

- last commit 4 days ago
- 27 commits in the last 90 days
- latest release v3.2.0 42 days ago
- 10.5k GitHub stars
- 22 contributors
- accepts sponsorship (Github, Patreon)
- backed by Erin Catto

## Alternatives

- [Matter.js](https://talira.ai/catalog/matter-js-egff3vpv.md): 2D rigid body physics engine for the web in JavaScript, with collisions, constraints and a canvas renderer

## Sources

[^1]: https://github.com/erincatto/box2d/blob/main/LICENSE (checked 28 Nov 2026)
[^2]: https://github.com/erincatto/box2d/blob/main/README.md (checked 28 Nov 2026)
