Developing apps with Fyne

Create your first Fyne app


Having completed the steps in the getting started document you’re ready to build your first app. To illustrate the process we will build a simple hello world application.

A simple app starts by creating an app instance with app.New() and then opening a window with app.NewWindow(). Then a widget tree is defined that is set as the main content with SetContent() on a window. The app UI is then shown by calling ShowAndRun() on the window.

  • Using Functions
  • Using Structs

The code above can be built using the command go build hello.go and then executed either by running the hello command or by double clicking the icon. You could also bypass the compiling step and just run the code directly using go run hello.go.

Either approach will show a window that looks just like this:

Hello Window

If you prefer a light theme then just set the environment variable FYNE_THEME=light and you’ll get:

Hello Light Theme

That’s all there is to getting started. You can find the full API documentation on GoDoc.org. If you prefer a curated process we have prepared a tour of the toolkit that you can launch using the button below.

Take the Tour

Get In Touch!


We're excited to hear from anyone interested in the project. Whether it's to find out more, provide suggestions or to get involved - drop us a line!

If you would like to join us on slack but are not yet signed up to the golang slack server you can request an invite.