28 releases (16 breaking)

Uses new Rust 2024

0.25.1 Oct 19, 2025
0.24.0 Oct 24, 2024
0.21.0 Jul 24, 2023
0.20.0 Jan 21, 2023
0.9.3 Apr 21, 2015

#56 in Game dev

Download history 574/week @ 2026-01-21 597/week @ 2026-01-28 491/week @ 2026-02-04 336/week @ 2026-02-11 723/week @ 2026-02-18 1259/week @ 2026-02-25 662/week @ 2026-03-04 519/week @ 2026-03-11 661/week @ 2026-03-18 529/week @ 2026-03-25 582/week @ 2026-04-01 475/week @ 2026-04-08 626/week @ 2026-04-15 703/week @ 2026-04-22 649/week @ 2026-04-29 409/week @ 2026-05-06

2,428 downloads per month
Used in 19 crates

zlib-acknowledgement

18MB
41K SLoC

C++ 28K SLoC // 0.2% comments Rust 8K SLoC // 0.0% comments Objective-C++ 4K SLoC // 0.3% comments Objective-C 195 SLoC // 0.5% comments Shell 1 SLoC

Contains (static library, 1.5MB) freetype.lib, (static library, 1.5MB) SFML/extlibs/libs-msvc/x64/freetype.lib, (static library, 1MB) libfreetype.a, (static library, 715KB) libvorbisenc.a, (static library, 1MB) libfreetype.a, (static library, 690KB) libvorbisenc.a and 24 more.

rust-sfml crates.io docs.rs Discord

Rust bindings for SFML, the Simple and Fast Multimedia Library.

Platform support

Platform Development and testing CI (basic tests)
🐧 Linux ✅ Most tested Status
🪟 Windows (MSVC) ⚠️ Rarely tested. Looking for testers/maintainers! Status
🐧 -> 🪟 (mingw-w64) ⚠️ Cross-compile from Linux to Windows. Somewhat tested.
🍎 Mac OS X ❌ Untested. Looking for testers/maintainers! Status

Prerequisites

  • Rust 1.86 or later
  • CMake, and a C++ toolchain for building SFML
  • 🐧 On Linux, you need the following dependencies installed:
    • Window module: libGL libX11 libXcursor libXrandr
    • Graphics module: libfreetype
    • Audio module: libopenal libvorbisenc libvorbisfile libvorbis

Documentation

The API documentation is available at: https://docs.rs/sfml/

If you need help with setting up rust-sfml on your system, you can take a look at the wiki.
Please take note that:

  • This wiki is supported by the community
  • The rust-sfml core team doesn't review it
  • Your contribution is welcome

License

This software is a binding of the SFML library created by Laurent Gomila, which is provided under the Zlib/png license.

This software is provided under the same license as SFML, the Zlib/png license.

Discord

rust-sfml users are welcome on the Official SFML Discord server

Dependencies