Kotlin and Vaadin for productive and fun web app development

Marcus Hellberg
Marcus Hellberg
On Jun 17, 2020 5:18:13 PM


Kotlin is a programming language that has gained a lot of popularity over the last few years. Its concise and expressive syntax feel liberating, compared to the verbosity of Java. Despite its simplicity, Kotlin is a fully type-safe language and helps you avoid many common programming errors in Java, such as null-pointer exceptions.

Kotlin runs on the JVM and is fully interoperable with existing Java code, which means that you can use it both in new and existing projects.

Can you build web applications with Kotlin?

Although Kotlin is well-known among developers as a language for building Android apps and backends, it's also great for building web apps. If you want to stay close to the browser API, you can compile Kotlin to JavaScript to build frontend applications, instead of using JavaScript.

A full-stack framework makes building web apps in Kotlin even easier. The Vaadin framework allows you to build web apps on a higher level of abstraction, working with components instead of DOM elements. Vaadin handles the communication between the server and browser transparently.

Vaadin: a full-stack web framework with Kotlin support

Vaadin is an open-source web framework for JVM backends. It features a large library of customizable UI components and supports an intuitive Kotlin DSL for building UIs declaratively.

verticalLayout {
	val nameField = textField("Your name")
	button("Say hello") {
		onLeftClick {"Hello, ${nameField.value}") }

Vaadin applications run on the JVM, so you have full access to backend services, databases, and other server resources as you build your app. The apps are secure by default thanks to Vaadin's unique architecture.

Get started: build a Kotlin web app with Vaadin

Here are some links to help you get started:

Please try it out and let us know what you think in the comments below!


Marcus Hellberg
Marcus Hellberg
Marcus works as the Director of Developer Relations at Vaadin. His daily work includes everything from writing blogs and tech demos to attending events and giving presentations on all things Vaadin and web-related. You can reach out to him on Twitter @marcushellberg.
Other posts by Marcus Hellberg