CINXE.COM

Get started with Kotlin | Kotlin Documentation

<!DOCTYPE html SYSTEM "about:legacy-compat"> <html lang="en-US" data-preset="contrast" data-primary-color="#307FFF"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"><meta charset="UTF-8"><meta name="built-on" content="2025-02-15T01:05:11.730123806"><meta name="build-number" content="3450"><link rel="canonical" href="https://kotlinlang.org/docs/getting-started.html" data-react-helmet="true"><script> (function (w, d, s, l, i) { w[l] = w[l] || []; w[l].push({'gtm.start': new Date().getTime(), event: 'gtm.js'}); var f = d.getElementsByTagName(s)[0], j = d.createElement(s), dl = l != 'dataLayer' ? '&amp;l=' + l : ''; j.async = true; j.src = '//www.googletagmanager.com/gtm.js?id=' + i + dl; f.parentNode.insertBefore(j, f); })(window, document, 'script', 'dataLayer', 'GTM-5P98'); </script> <script src="static/v3/analytics.js"></script> <title>Get started with Kotlin | Kotlin Documentation</title><script type="application/json" id="virtual-toc-data">[{"id":"install-kotlin","level":0,"title":"Install Kotlin","anchor":"#install-kotlin"},{"id":"choose-your-kotlin-use-case","level":0,"title":"Choose your Kotlin use case","anchor":"#choose-your-kotlin-use-case"},{"id":"is-anything-missing","level":0,"title":"Is anything missing?","anchor":"#is-anything-missing"}]</script><script type="application/json" id="topic-shortcuts"></script><link href="static/v3/app.css?v=6.11.0-footer" rel="stylesheet"><link rel="icon" type="image/svg" sizes="16x16" href="https://kotlinlang.org/assets/images/favicon.svg?v2"><link rel="icon" type="image/x-icon" sizes="32x32" href="https://kotlinlang.org/assets/images/favicon.ico?v2"><link rel="icon" type="image/png" sizes="96x96" href="https://kotlinlang.org/assets/images/apple-touch-icon.png?v2"><link rel="icon" type="image/png" sizes="300x300" href="https://kotlinlang.org/assets/images/apple-touch-icon-72x72.png?v2"><link rel="icon" type="image/png" sizes="500x500" href="https://kotlinlang.org/assets/images/apple-touch-icon-114x114.png?v2"><meta name="image" content="https://kotlinlang.org/assets/images/open-graph/docs.png"><!-- Open Graph --><meta property="og:title" content="Get started with Kotlin | Kotlin"><meta property="og:description" content=""><meta property="og:image" content="https://kotlinlang.org/assets/images/open-graph/docs.png"><meta property="og:site_name" content="Kotlin Help"><meta property="og:type" content="website"><meta property="og:locale" content="en_US"><meta property="og:url" content="https://kotlinlang.org/docs/getting-started.html"><!-- End Open Graph --><!-- Twitter Card --><meta name="twitter:card" content="summary_large_image"><meta name="twitter:site" content="@kotlin"><meta name="twitter:title" content="Get started with Kotlin | Kotlin"><meta name="twitter:description" content=""><meta name="twitter:creator" content="@kotlin"><meta name="twitter:image:src" content="https://kotlinlang.org/assets/images/open-graph/docs.png"><!-- End Twitter Card --><!-- Schema.org WebPage --><script type="application/ld+json">{ "@context": "http://schema.org", "@type": "WebPage", "@id": "https://kotlinlang.org/docs/getting-started.html#webpage", "url": "https://kotlinlang.org/docs/getting-started.html", "name": "Get started with Kotlin | Kotlin", "description": "", "image": "https://kotlinlang.org/assets/images/open-graph/docs.png", "inLanguage":"en-US" }</script><!-- End Schema.org --><!-- Schema.org WebSite --><script type="application/ld+json">{ "@type": "WebSite", "@id": "https://kotlinlang.org/docs/#website", "url": "https://kotlinlang.org/docs/", "name": "Kotlin Help" }</script><!-- End Schema.org --><style>a[href="test-page.html"] { visibility: hidden; }</style></head><body data-id="getting-started" data-main-title="Get started with Kotlin" data-article-props="{&quot;seeAlsoStyle&quot;:&quot;links&quot;}" data-template="article" data-breadcrumbs="" data-edit-url="https://github.com/JetBrains/kotlin-web-site/edit/master/docs/topics/getting-started.md"><div class="wrapper"><main class="panel _main"><header class="panel__header"><div class="container"><h3>Kotlin Help</h3><div class="panel-trigger"></div></div></header><section class="panel__content"><div class="container"><article class="article" data-shortcut-switcher="inactive"><h1 data-toc="getting-started" id="getting-started.md">Get started with Kotlin</h1><p id="f60oyo_2">Kotlin is a modern but already mature programming language designed to make developers happier. It's concise, safe, interoperable with Java and other languages, and provides many ways to reuse code between multiple platforms for productive programming.</p><p id="f60oyo_3">To start, why not take our tour of Kotlin? This tour covers the fundamentals of the Kotlin programming language and can be completed entirely within your browser.</p><p id="f60oyo_4"><a href="kotlin-tour-welcome.html" id="f60oyo_8"><figure id="f60oyo_9"><img alt="Start the Kotlin tour" src="images/start-kotlin-tour.svg" title="Start the Kotlin tour" width="700" height="700"></figure></a></p><section class="chapter"><h2 id="install-kotlin" data-toc="install-kotlin">Install Kotlin</h2><p id="f60oyo_10">Kotlin is included in each <a href="https://www.jetbrains.com/idea/download/" id="f60oyo_11" data-external="true" rel="noopener noreferrer">IntelliJ IDEA</a> and <a href="https://developer.android.com/studio" id="f60oyo_12" data-external="true" rel="noopener noreferrer">Android Studio</a> release. Download and install one of these IDEs to start using Kotlin.</p></section><section class="chapter"><h2 id="choose-your-kotlin-use-case" data-toc="choose-your-kotlin-use-case">Choose your Kotlin use case</h2><div class="tabs" id="f60oyo_13" data-anchors="[android,backend,console,cross-platform-mobile,data-analysis]"><div class="tabs__content" data-gtm="tab" id="console" data-title="Console"><p id="f60oyo_19">Here you'll learn how to develop a console application and create unit tests with Kotlin.</p><ol class="list _decimal" id="f60oyo_20" type="1"><li class="list__item" id="f60oyo_22"><p id="f60oyo_26"><span class="control" id="f60oyo_27"><a href="jvm-get-started.html" id="f60oyo_28">Create a basic JVM application with the IntelliJ IDEA project wizard</a>.</span></p></li><li class="list__item" id="f60oyo_23"><p id="f60oyo_29"><span class="control" id="f60oyo_30"><a href="jvm-test-using-junit.html" id="f60oyo_31">Write your first unit test</a>.</span></p></li><li class="list__item" id="f60oyo_24"><p id="f60oyo_32"><span class="control" id="f60oyo_34">Join the Kotlin community:</span></p><ul class="list _bullet" id="f60oyo_33"><li class="list__item" id="f60oyo_35"><p><img alt="Slack" src="images/slack.svg" class="inline-icon-" title="Slack" id="f60oyo_37" width="25" height="25"> Slack: <a href="https://surveys.jetbrains.com/s3/kotlin-slack-sign-up" id="f60oyo_38" data-external="true" rel="noopener noreferrer">get an invite</a>.</p></li><li class="list__item" id="f60oyo_36"><p><img alt="StackOverflow" src="images/stackoverflow.svg" class="inline-icon-" title="StackOverflow" id="f60oyo_39" width="25" height="25"> StackOverflow: subscribe to the <a href="https://stackoverflow.com/questions/tagged/kotlin" id="f60oyo_40" data-external="true" rel="noopener noreferrer">&quot;kotlin&quot;</a> tag.</p></li></ul></li><li class="list__item" id="f60oyo_25"><p id="f60oyo_41"><span class="control" id="f60oyo_43">Follow Kotlin</span> on:</p><ul class="list _bullet" id="f60oyo_42"><li class="list__item" id="f60oyo_44"><p><img alt="Twitter" src="images/twitter.svg" class="inline-icon-" title="Twitter" id="f60oyo_47" width="18" height="18"> <a href="https://twitter.com/kotlin" id="f60oyo_48" data-external="true" rel="noopener noreferrer">Twitter</a></p></li><li class="list__item" id="f60oyo_45"><p><img alt="Reddit" src="images/reddit.svg" class="inline-icon-" title="Reddit" id="f60oyo_49" width="25" height="25"> <a href="https://www.reddit.com/r/Kotlin/" id="f60oyo_50" data-external="true" rel="noopener noreferrer">Reddit</a></p></li><li class="list__item" id="f60oyo_46"><p><img alt="YouTube" src="images/youtube.svg" class="inline-icon-" title="YouTube" id="f60oyo_51" width="25" height="25"> <a href="https://www.youtube.com/channel/UCP7uiEZIqci43m22KDl0sNw" id="f60oyo_52" data-external="true" rel="noopener noreferrer">Youtube</a></p></li></ul></li></ol><p id="f60oyo_21">If you encounter any difficulties or problems, report an issue in our <a href="https://youtrack.jetbrains.com/issues/KT" id="f60oyo_53" data-external="true" rel="noopener noreferrer">issue tracker</a>.</p></div><div class="tabs__content" data-gtm="tab" id="backend" data-title="Backend"><p id="f60oyo_54">Here you'll learn how to develop a backend application with Kotlin server-side.</p><ol class="list _decimal" id="f60oyo_55" type="1"><li class="list__item" id="f60oyo_57"><p id="f60oyo_61"><span class="control" id="f60oyo_63">Create your first backend application:</span></p><ul class="list _bullet" id="f60oyo_62"><li class="list__item" id="f60oyo_64"><p><a href="jvm-get-started-spring-boot.html" id="f60oyo_66">Create a RESTful web service with Spring Boot</a>.</p></li><li class="list__item" id="f60oyo_65"><p><a href="https://ktor.io/docs/creating-http-apis.html" id="f60oyo_67" data-external="true" rel="noopener noreferrer">Create HTTP APIs with Ktor</a>.</p></li></ul></li><li class="list__item" id="f60oyo_58"><p id="f60oyo_68"><span class="control" id="f60oyo_69"><a href="mixing-java-kotlin-intellij.html" id="f60oyo_70">Learn how to mix Kotlin and Java code in your application</a>.</span></p></li><li class="list__item" id="f60oyo_59"><p id="f60oyo_71"><span class="control" id="f60oyo_73">Join the Kotlin server-side community:</span></p><ul class="list _bullet" id="f60oyo_72"><li class="list__item" id="f60oyo_74"><p><img alt="Slack" src="images/slack.svg" class="inline-icon-" title="Slack" id="f60oyo_76" width="25" height="25"> Slack: <a href="https://surveys.jetbrains.com/s3/kotlin-slack-sign-up" id="f60oyo_77" data-external="true" rel="noopener noreferrer">get an invite</a>.</p></li><li class="list__item" id="f60oyo_75"><p><img alt="StackOverflow" src="images/stackoverflow.svg" class="inline-icon-" title="StackOverflow" id="f60oyo_78" width="25" height="25"> StackOverflow: subscribe to the <a href="https://stackoverflow.com/questions/tagged/kotlin" id="f60oyo_79" data-external="true" rel="noopener noreferrer">&quot;kotlin&quot;</a> tag.</p></li></ul></li><li class="list__item" id="f60oyo_60"><p id="f60oyo_80"><span class="control" id="f60oyo_82">Follow Kotlin</span> on:</p><ul class="list _bullet" id="f60oyo_81"><li class="list__item" id="f60oyo_83"><p><img alt="Twitter" src="images/twitter.svg" class="inline-icon-" title="Twitter" id="f60oyo_86" width="18" height="18"> <a href="https://twitter.com/kotlin" id="f60oyo_87" data-external="true" rel="noopener noreferrer">Twitter</a></p></li><li class="list__item" id="f60oyo_84"><p><img alt="Reddit" src="images/reddit.svg" class="inline-icon-" title="Reddit" id="f60oyo_88" width="25" height="25"> <a href="https://www.reddit.com/r/Kotlin/" id="f60oyo_89" data-external="true" rel="noopener noreferrer">Reddit</a></p></li><li class="list__item" id="f60oyo_85"><p><img alt="YouTube" src="images/youtube.svg" class="inline-icon-" title="YouTube" id="f60oyo_90" width="25" height="25"> <a href="https://www.youtube.com/channel/UCP7uiEZIqci43m22KDl0sNw" id="f60oyo_91" data-external="true" rel="noopener noreferrer">Youtube</a></p></li></ul></li></ol><p id="f60oyo_56">If you encounter any difficulties or problems, report an issue in our <a href="https://youtrack.jetbrains.com/issues/KT" id="f60oyo_92" data-external="true" rel="noopener noreferrer">issue tracker</a>.</p></div><div class="tabs__content" data-gtm="tab" id="cross-platform-mobile" data-title="Cross-platform"><p id="f60oyo_93">Here you'll learn how to develop a cross-platform application using <a href="multiplatform-intro.html" id="f60oyo_96">Kotlin Multiplatform</a>.</p><ol class="list _decimal" id="f60oyo_94" type="1"><li class="list__item" id="f60oyo_97"><p id="f60oyo_102"><span class="control" id="f60oyo_103"><a href="https://www.jetbrains.com/help/kotlin-multiplatform-dev/multiplatform-setup.html" id="f60oyo_104" data-external="true" rel="noopener noreferrer">Set up your environment for cross-platform development</a>.</span></p></li><li class="list__item" id="f60oyo_98"><p id="f60oyo_105"><span class="control" id="f60oyo_107">Create your first application for iOS and Android:</span></p><ul class="list _bullet" id="f60oyo_106"><li class="list__item" id="f60oyo_108"><p><a href="https://www.jetbrains.com/help/kotlin-multiplatform-dev/multiplatform-create-first-app.html" id="f60oyo_111" data-external="true" rel="noopener noreferrer">Create a basic cross-platform application from scratch with the project wizard</a>.</p></li><li class="list__item" id="f60oyo_109"><p><a href="https://www.jetbrains.com/help/kotlin-multiplatform-dev/multiplatform-integrate-in-existing-app.html" id="f60oyo_112" data-external="true" rel="noopener noreferrer">Make your existing Android application work on iOS</a>.</p></li><li class="list__item" id="f60oyo_110"><p><a href="https://www.jetbrains.com/help/kotlin-multiplatform-dev/multiplatform-ktor-sqldelight.html" id="f60oyo_113" data-external="true" rel="noopener noreferrer">Create a cross-platform application using Ktor and SQLdelight</a>.</p></li></ul></li><li class="list__item" id="f60oyo_99"><p id="f60oyo_114"><span class="control" id="f60oyo_115">Explore <a href="https://www.jetbrains.com/help/kotlin-multiplatform-dev/multiplatform-samples.html" id="f60oyo_116" data-external="true" rel="noopener noreferrer">sample projects</a></span>.</p></li><li class="list__item" id="f60oyo_100"><p id="f60oyo_117"><span class="control" id="f60oyo_119">Join the Kotlin Multiplatform community:</span></p><ul class="list _bullet" id="f60oyo_118"><li class="list__item" id="f60oyo_120"><p><img alt="Slack" src="images/slack.svg" class="inline-icon-" title="Slack" id="f60oyo_122" width="25" height="25"> Slack: <a href="https://surveys.jetbrains.com/s3/kotlin-slack-sign-up" id="f60oyo_123" data-external="true" rel="noopener noreferrer">get an invite</a> and join the <a href="https://kotlinlang.slack.com/archives/C0B8MA7FA" id="f60oyo_124" data-external="true" rel="noopener noreferrer">#getting-started</a> and <a href="https://kotlinlang.slack.com/archives/C3PQML5NU" id="f60oyo_125" data-external="true" rel="noopener noreferrer">#multiplatform</a> channels.</p></li><li class="list__item" id="f60oyo_121"><p><img alt="StackOverflow" src="images/stackoverflow.svg" class="inline-icon-" title="StackOverflow" id="f60oyo_126" width="25" height="25"> StackOverflow: Subscribe to the <a href="https://stackoverflow.com/questions/tagged/kotlin-multiplatform" id="f60oyo_127" data-external="true" rel="noopener noreferrer">&quot;kotlin-multiplatform&quot; tag</a>.</p></li></ul></li><li class="list__item" id="f60oyo_101"><p id="f60oyo_128"><span class="control" id="f60oyo_130">Follow Kotlin</span> on:</p><ul class="list _bullet" id="f60oyo_129"><li class="list__item" id="f60oyo_131"><p><img alt="Twitter" src="images/twitter.svg" class="inline-icon-" title="Twitter" id="f60oyo_134" width="18" height="18"> <a href="https://twitter.com/kotlin" id="f60oyo_135" data-external="true" rel="noopener noreferrer">Twitter</a></p></li><li class="list__item" id="f60oyo_132"><p><img alt="Reddit" src="images/reddit.svg" class="inline-icon-" title="Reddit" id="f60oyo_136" width="25" height="25"> <a href="https://www.reddit.com/r/Kotlin/" id="f60oyo_137" data-external="true" rel="noopener noreferrer">Reddit</a></p></li><li class="list__item" id="f60oyo_133"><p><img alt="YouTube" src="images/youtube.svg" class="inline-icon-" title="YouTube" id="f60oyo_138" width="25" height="25"> <a href="https://www.youtube.com/channel/UCP7uiEZIqci43m22KDl0sNw" id="f60oyo_139" data-external="true" rel="noopener noreferrer">Youtube</a></p></li></ul></li></ol><p id="f60oyo_95">If you encounter any difficulties or problems, report an issue to our <a href="https://youtrack.jetbrains.com/issues/KT" id="f60oyo_140" data-external="true" rel="noopener noreferrer">issue tracker</a>.</p></div><div class="tabs__content" data-gtm="tab" id="android" data-title="Android"><p id="f60oyo_141">To start using Kotlin for Android development, read <a href="https://developer.android.com/kotlin/get-started" id="f60oyo_144" data-external="true" rel="noopener noreferrer">Google's recommendation for getting started with Kotlin on Android</a>.</p><p id="f60oyo_142">Join the Android community on <img alt="Slack" src="images/slack.svg" class="inline-icon-" title="Slack" id="f60oyo_145" width="25" height="25"> Slack: <a href="https://surveys.jetbrains.com/s3/kotlin-slack-sign-up" id="f60oyo_146" data-external="true" rel="noopener noreferrer">get an invite</a> and join the <a href="https://kotlinlang.slack.com/archives/C0B8M7BUY" id="f60oyo_147" data-external="true" rel="noopener noreferrer">#android</a> channel.</p><p id="f60oyo_143">Follow Kotlin on <img alt="Twitter" src="images/twitter.svg" class="inline-icon-" title="Twitter" id="f60oyo_148" width="18" height="18"> <a href="https://twitter.com/kotlin" id="f60oyo_149" data-external="true" rel="noopener noreferrer">Twitter</a>, <img alt="Reddit" src="images/reddit.svg" class="inline-icon-" title="Reddit" id="f60oyo_150" width="25" height="25"> <a href="https://www.reddit.com/r/Kotlin/" id="f60oyo_151" data-external="true" rel="noopener noreferrer">Reddit</a>, and <img alt="YouTube" src="images/youtube.svg" class="inline-icon-" title="YouTube" id="f60oyo_152" width="25" height="25"> <a href="https://www.youtube.com/channel/UCP7uiEZIqci43m22KDl0sNw" id="f60oyo_153" data-external="true" rel="noopener noreferrer">Youtube</a>, and don't miss any important ecosystem updates.</p></div><div class="tabs__content" data-gtm="tab" id="data-analysis" data-title="Data analysis"><p id="f60oyo_154">From building data pipelines to productionizing machine learning models, Kotlin is a great choice for working with data and getting the most out of it.</p><ol class="list _decimal" id="f60oyo_155" type="1"><li class="list__item" id="f60oyo_156"><p id="f60oyo_160"><span class="control" id="f60oyo_162">Create and edit notebooks seamlessly within the IDE:</span></p><ul class="list _bullet" id="f60oyo_161"><li class="list__item" id="f60oyo_163"><p><a href="get-started-with-kotlin-notebooks.html" id="f60oyo_164">Get started with Kotlin Notebook</a>.</p></li></ul></li><li class="list__item" id="f60oyo_157"><p id="f60oyo_165"><span class="control" id="f60oyo_167">Explore and experiment with your data:</span></p><ul class="list _bullet" id="f60oyo_166"><li class="list__item" id="f60oyo_168"><p><a href="https://kotlin.github.io/dataframe/overview.html" id="f60oyo_170" data-external="true" rel="noopener noreferrer">DataFrame</a> &ndash; a library for data analysis and manipulation.</p></li><li class="list__item" id="f60oyo_169"><p><a href="https://kotlin.github.io/kandy/welcome.html" id="f60oyo_171" data-external="true" rel="noopener noreferrer">Kandy</a> &ndash; a plotting tool for data visualization.</p></li></ul></li><li class="list__item" id="f60oyo_158"><p id="f60oyo_172"><span class="control" id="f60oyo_174">Get the latest updates about Kotlin for Data Analysis:</span></p><ul class="list _bullet" id="f60oyo_173"><li class="list__item" id="f60oyo_175"><p><img alt="Slack" src="images/slack.svg" class="inline-icon-" title="Slack" id="f60oyo_177" width="25" height="25"> Slack: <a href="https://surveys.jetbrains.com/s3/kotlin-slack-sign-up" id="f60oyo_178" data-external="true" rel="noopener noreferrer">get an invite</a> and join the <a href="https://kotlinlang.slack.com/archives/C4W52CFEZ" id="f60oyo_179" data-external="true" rel="noopener noreferrer">#datascience</a> channel.</p></li><li class="list__item" id="f60oyo_176"><p><img alt="Twitter" src="images/twitter.svg" class="inline-icon-" title="Twitter" id="f60oyo_180" width="18" height="18"> Twitter: follow <a href="http://twitter.com/KotlinForData" id="f60oyo_181" data-external="true" rel="noopener noreferrer">KotlinForData</a>.</p></li></ul></li><li class="list__item" id="f60oyo_159"><p id="f60oyo_182"><span class="control" id="f60oyo_184">Follow Kotlin</span> on:</p><ul class="list _bullet" id="f60oyo_183"><li class="list__item" id="f60oyo_185"><p><img alt="Twitter" src="images/twitter.svg" class="inline-icon-" title="Twitter" id="f60oyo_188" width="18" height="18"> <a href="https://twitter.com/kotlin" id="f60oyo_189" data-external="true" rel="noopener noreferrer">Twitter</a></p></li><li class="list__item" id="f60oyo_186"><p><img alt="Reddit" src="images/reddit.svg" class="inline-icon-" title="Reddit" id="f60oyo_190" width="25" height="25"> <a href="https://www.reddit.com/r/Kotlin/" id="f60oyo_191" data-external="true" rel="noopener noreferrer">Reddit</a></p></li><li class="list__item" id="f60oyo_187"><p><img alt="YouTube" src="images/youtube.svg" class="inline-icon-" title="YouTube" id="f60oyo_192" width="25" height="25"> <a href="https://www.youtube.com/channel/UCP7uiEZIqci43m22KDl0sNw" id="f60oyo_193" data-external="true" rel="noopener noreferrer">Youtube</a></p></li></ul></li></ol></div></div></section><section class="chapter"><h2 id="is-anything-missing" data-toc="is-anything-missing">Is anything missing?</h2><p id="f60oyo_194">If anything is missing or seems confusing on this page, please <a href="https://surveys.hotjar.com/d82e82b0-00d9-44a7-b793-0611bf6189df" id="f60oyo_195" data-external="true" rel="noopener noreferrer">share your feedback</a>.</p></section><div class="last-modified">Last modified: 10 December 2024</div><div data-feedback-placeholder="true"></div><div class="navigation-links _bottom"><a href="home.html" class="navigation-links__prev">Kotlin Docs</a><a href="kotlin-tour-welcome.html" class="navigation-links__next">Welcome to our tour of Kotlin!</a></div></article><div id="disqus_thread"></div></div></section></main></div><script src="static/v3/app.js"></script></body></html>

Pages: 1 2 3 4 5 6 7 8 9 10