GLFW is an Open Source, multi-platform library for OpenGL, OpenGL ES and Vulkan application development. It provides a simple, platform-independent API for creating windows, contexts and surfaces, reading input, handling events, etc.
GLFW is licensed under the zlib/libpng license.
This is version 3.2.1, which adds support for statically linking the Vulkan loader and fixes for a number of bugs that together affect all supported platforms.
See the downloads page for details and files, or fetch the
latest branch, which always points to the latest stable release. Each release starting with 3.0 also has a corresponding annotated tag with source and binary archives.
If you are new to GLFW, you may find the tutorial for GLFW 3 useful. If you have used GLFW 2 in the past, there is a transition guide for moving to the GLFW 3 API.
GLFW itself requires only the headers and libraries for your window system. It does not need the headers for any context creation API (WGL, GLX, EGL, NSGL) or rendering API (OpenGL, OpenGL ES, Vulkan) to enable support for them.
GLFW supports compilation on Windows with Visual C++ 2010 and later, MinGW and MinGW-w64, on OS X with Clang and on Linux and other Unix-like systems with GCC and Clang. It will likely compile in other environments as well, but this is not regularly tested.
There are also pre-compiled Windows binaries available for all compilers supported on that platform.
See the compilation guide in the documentation for more information.
See the building application guide guide in the documentation for more information.
GLFW supports Windows XP and later, OS X 10.7 Lion and later, and Linux and other Unix-like systems with the X Window System. Experimental implementations for the Wayland protocol and the Mir display server are available but not yet officially supported.
See the compatibility guide in the documentation for more information.
GLFW itself depends only on the headers and libraries for your window system.
The examples and test programs depend on a number of tiny libraries. These are located in the
The Vulkan example additionally requires the Vulkan SDK to be installed, or it will not be included in the build.
The documentation is generated with Doxygen. If CMake does not find Doxygen, the documentation will not be generated when you build.
Bugs are reported to our issue tracker. Please check the contribution guide for information on what to include when reporting a bug.
_GLFW_VULKAN_STATICbuild macro to make the library use the Vulkan loader linked statically into the application (#820)
glfwSetCursorPosused the wrong minimum (#773)
GLFW_INCLUDE_VULKANwhen compiling the library did not fail with the expected error message (#823)
CMAKE_MODULE_PATHwas clobbered (#822)
glfwSetClipboardStringcreated an unnecessary intermediate copy of the string
GLFW_MAXIMIZEDhint when the process was provided a
BadMatchon some non-reparenting WMs (#789,#798)
glfwSetWindowPosoperated on the window frame instead of the client area (#800)
libprefix matching between EGL and OpenGL ES library binaries
On glfw.org you can find the latest version of GLFW, as well as news, documentation and other information about the project.
If you have questions related to the use of GLFW, we have a forum, and the
#glfw IRC channel on Freenode.
If you have a bug to report, a patch to submit or a feature you'd like to request, please file it in the issue tracker on GitHub.
Finally, if you're interested in helping out with the development of GLFW or porting it to your favorite platform, join us on the forum, GitHub or IRC.
GLFW exists because people around the world donated their time and lent their skills.