Quick Start

Hover is a simple build tool to create 'go-'flutter desktop applications.


Hover uses Go to build your Flutter application to desktop. Hover itself is also written using the Go language. You will need to install go on your development machine. Then install hover like this:

go get -u github.com/go-flutter-desktop/hover

If you get this error: cmdApp.ProcessState.ExitCode undefined (type *os.ProcessState has no field or method ExitCode), then update Go to at least version 1.12.

Run the same command to update when a newer version becomes available.

Install these dependencies:

  • You need to make sure you have a C compiler.
    The recommended C compiler are documented here.

  • You need to make sure you have dependencies of GLFW:

    • On macOS, you need Xcode or Command Line Tools for Xcode (xcode-select --install) for required headers and libraries.
    • On Ubuntu/Debian-like Linux distributions, you need libgl1-mesa-dev xorg-dev packages.
    • On CentOS/Fedora-like Linux distributions, you need libX11-devel libXcursor-devel libXrandr-devel libXinerama-devel mesa-libGL-devel libXi-devel packages.
    • See here for full details.


The first time you use hover for a project, you’ll need to initialize the project for desktop. hover init requires a project path. This is usualy the path for your project on github or a self-hosted git service. If you are unsure, just make something up, it can always be changed later.

First, cd into a flutter project.

cd projects/simpleApplication
hover init github.com/my-organization/simpleApplication

This creates the directory desktop and adds boilerplate files such as Go code and a default logo.

Make sure you have the following main_desktop.dart in the root librairie of your application.

Optionally, you may add plugins to desktop/cmd/options.go
Optionally, change the logo in desktop/assets/logo.png, which is used as icon for the window.

Run with hot-restart

To run the application and attach flutter for hot-reload support:

hover run

By default, hover uses the file lib/main_desktop.dart as entrypoint. You may specify a different endpoint by using the --target flag.

The hot-reload is manual because you’ll need to press ‘r’ in the terminal to hot-reload the application.

If you want to integrate go-flutter with VSCode, read this issue.