Dotlin logo

Dotlin is a Kotlin to Dart compiler. The aim is to integrate Kotlin as a language
into the Dart ecosystem, combing best of both worlds: The Kotlin language & standard library,
and the Dart ecosystem & build system.

About Dotlin

Dotlin makes use of Kotlin’s IR (Immediate Representation) compiler, and uses that to generate Dart source code.
At the moment only a small subset of Kotlin’s features are supported, to see what exactly, you can
look at the TODO.


  • Support all Kotlin language features
  • Support the Kotlin standard library
  • Allow the use of any library written in Dart by generating external Kotlin APIs
  • Generate code that is still readable and pleasant to use for Dart consumers
  • Integrate with Dart’s build system (e.g. use pubspec.yaml to define dependencies)
  • Create an IntelliJ/Fleet plugin
  • Support Flutter
    • Flutter: Allow seamless Dart-Kotlin to Android-Kotlin integration (and possibly Swift)
    • Flutter: Create a fluent widget builder DSL using Kotlin’s scope functions on top of the generated external API


Dotlin, at this point in time, should not be used for any production projects. If you want to try
it out, clone the repo and you can then build it with

./gradlew build distZip

Then you can find Dotlin in build/distributions/dotlin-<version>.zip.

In there, there’s a bin/dotlin executable you can try out.


Since the project is at an early stage, a lot is still changing and therefore — for now — code contributions
are not encouraged. However, in the future when Dotlin is in a more stable state this will definitely change.

When code contributions are encouraged, you are required to sign off all of your commits:

My commit message

Signed-off-by: Jan Jansen <[email protected]>

By contributing and signing off your commits, you agree to the Developer Certificate of Origin (DCO), which you can
read here.

For now however, it is encouraged to try Dotlin out, and if you notice anything odd, or want to request a feature/improvement, to create
an issue.


Dotlin itself is licensed under the AGPL.

Note that this does not apply to code generated by Dotlin. Code generated by Dotlin can be used in projects of any license.

All libraries used by consumers (e.g. the Kotlin standard library implementation, the Dart core Kotlin definitions) are
licensed under the Apache 2.0.

The Dotlin logo (docs/assets/dotlin.png) is licensed under CC BY-NC-ND 4.0.


View Github