Integrate a fully functional web browser into your Godot 4.2+ games for Linux, Windows (and for macOS, we need contributors!). This GDExtension wraps the Chromium Embedded Framework (CEF) API, allowing you to display web content in 2D and 3D scenes using GDScript.
โ ๏ธ Godot 3 users: Please use the godot-3.x branch instead.
๐ฅ Click the picture to watch the YouTube video "I made my own Browser" by FaceDev!
๐ฆgdCEF โฃ ๐ build.py โฌ
๏ธ Python3 script for compiling the project โฃ ๐ฆ cef_artifacts โฌ
๏ธ Folder with CEF and gdCEF artifacts created by build.py โฃ ๐ demos โฌ
๏ธ Several examples of usage of gdCEF โฃ ๐ doc โฌ
๏ธ Several documents to teach you how to use gdCEF โฃ ๐ gdcef โฌ
๏ธ C++ code source of the gdextension (to be compiled) โ โฃ ๐ browser โฌ
๏ธ Code for the CEF main process (libgdcef used by CEF) โ โฃ ๐ subprocess โฌ
๏ธ Code for the CEF secondary process (gdCefRenderProcess used by libgdcef) โ โฃ ๐ patches โฌ
๏ธ Patch files to apply to the CEF source code โ โ ๐ tests โฌ
๏ธ Unit tests โ ๐ thirdparty โฌ
๏ธ Downloaded packages by build.py โฃ ๐ cef_binary โฌ
๏ธ CEF distribution used to build dependencies (downloaded) โ ๐ godot-cpp โฌ
๏ธ Godot C++ API and bindings (downloaded) python3 -m pip install -r requirements.txt python3 build.pyThe cef_artifacts folder will be created at the project root with all necessary files.
Depending on your computer but count around 15 min to compile:
- download and compile godot-cpp.
- download and compile CEF.
- compile gdCEF.
- โฌ๏ธ Download the latest release from GitHub Releases.
- ๐ Extract and copy the
cef_artifactsfolder into your Godot project. - โ
Done! The
.gdextensionfile is already included in the folder.
- ๐๏ธ Open the Godot editor, and click the "AssetLib" button.
- ๐ In the search bar, type
gdcef. - ๐ Download the
cef_artifactsfolder into your Godot project. Be sure to have clicked on "Ignore asset root". โ ๏ธ Godot does not preserve file attributes. Callcd cef_artifacts/linux/ && chmod +x *.so gdCefRenderProcessto restore them.- โ
Done! The
.gdextensionfile is already included in the folder.
- Create a gdCEF node in your scene graph.
- Create a TextureRect in your scene graph.
- Create a gdscript with the following basic content:
extends GDCEF func _ready(): $CEF.initialize({}) var browser = $CEF.create_browser("https://godotengine.org", $TextureRect, {})
โ ๏ธ This minimal example needs more code to have a usable browser in your game. See the Getting Started Guide for detailed instructions.
| Document | Description |
|---|---|
| Getting Started | ๐ How to integrate gdCEF in your project |
| API Reference | ๐ Complete GDScript API documentation |
| Installation | ๐ง Detailed compilation instructions |
| FAQ | โ Common questions and troubleshooting |
| Architecture | ๐๏ธ How CEF works internally |
| Design Details | ๐๏ธ Repository organization and build system |
| Gallery | ๐ผ๏ธ Gallery of projects using gdCEF |
Ready-to-use demos are included in the demos/ folder:
| Demo | Description |
|---|---|
| Hello CEF | ๐ Minimal example to start with |
| 2D Demo | ๐ Full-featured browser with tabs, showcasing most of the API |
| 3D Demo | ๐ Browser in a 3D scene with spatial audio |
| JS Bindings | ๐ JavaScript to GDScript communication |
| Project | Description |
|---|---|
| godot_wry | ๐ฆ WebView in Rust |
| GodotWebView | ๐งฉ Qt-based solution |
| GodotChrome | ๐ค Android/Godot 3 |
This project is licensed under the MIT License.
โ ๏ธ Note: CEF uses LGPL third-party libraries. See the FAQ for licensing implications.

