• Tim Buchalka

Java or Kotlin for Android Development – Which One Is Better?

Should you focus on Kotlin or Java for Android app development?


The question was which programming language should I focus on for Android app development? Kotlin, which is relatively new to the scene, or Java, which is the old language which has been around for many many years?


In general, my advice is for new projects to focus on Kotlin. The reason for that is that’s an up and coming language and over the last two years, in particular, Google has been heavily promoting Kotlin as the alternative for programming Android apps. I think there are a few reasons for that, although it’s not been said officially by Google. I think the fact that they’re in a dispute with Oracle over the use of Java is something that’s weighing on their mind and they’re looking to free themselves perhaps from that license restrictions because there’s a lot of ongoing arguments and court cases actually involved with Oracle and Google over the use of Java in Android app development.


I think in the long term we’re gonna see a similar situation with Kotlin and Java as we saw with Swift and Objective C with iOS development. That’s where Apple, they used Objective C for many years and transitioned fairly quickly over to Swift. Now, I would say that Objective C, although it’s still being used for legacy applications, which are applications that were developed prior to Swift coming out, I think certainly the vast majority of programming projects coming out now are worked or actually created in Swift.


So the same’s gonna happen with Google I think, already now statistically, I think I saw a Google slide at their last Google IO in June that talked about Kotlin already starting to overtake Java for new projects. I think that’s gonna happen so I think if you’re an existing Java developer, now would be a great time to start learning Kotlin. So set yourself up so you’ve got those skills so that when Kotlin really does become the mainstream and most new projects are written in Kotlin, you’ve really got at least a basic knowledge of Kotlin to be able to be productive. If you’re just starting out for the first time and you haven’t programmed in Java or Kotlin, my recommendation would be to start with Kotlin and that’s because it’s the new sexy language and that’s gonna look very good on your resumé. But I would also still, if I was in your shoes, put some time into learning Java because Java’s such a big language, such a popular language, and even as we relate it back to Android app development there are so many existing projects written in Java. So, in other words, you’re gonna be coming across Java in your day-to-day project work anyway, be that for legacy applications where you’re perhaps writing part of a new application, or part of an application in Kotlin and perhaps you’re working with a Java component as well.


So you really do need to know both. But if I was starting out as an Android app developer in 2019, I would focus on Kotlin first, but I would also make sure I’ve got some Java skills so that I can be basically a more productive programmer as well. Alright, so I hope that helped. If you’ve got any questions, feel free to leave a comment and I’ll get back to you.

© 2019 Tim Buchalka