Skip to main content
ProductsDesktop toolsTASTECADDrawing reviewTASTEFILESFile managementTASTEFTPFile transferTASTESSHRemote workspaceTASTEZIPCompression and extractionTASTEWINMFile managementDeveloper toolsTASTECODERust integrated development environmentTASTESTUDIOIntegrated development and test environmentTASTEETLData integration (ETL)ServersTASTEREMOTERemote desktop serverTASTEGEOGeospatial serverTASTEMAILMail workspaceInvestingTASTESTOCKStock auto-trading desktop appGet startedDownloadsDocumentationBuyAll products
Marketplace
News
TechNewsToday's dev newsDeveloper docsProgramming languagesRustTypeScriptJavaScriptPythonGoC#JavaCC++KotlinDartWeb front-end frameworksNext.jsReactVue.js · NuxtSvelteKitAngularServer frameworksSpring BootDjangoFastAPIASP.NET CoreNestJS · ExpressApp & desktop frameworksTauriFlutterReact NativeElectronAlgorithmsAlgorithm basicsCore algorithmsAdvanced algorithmsPractical algorithms
CommunityProjectsDevelopment logsPromptsAI tool issuesShowcaseCommunity guide
Work with usTech transferWebsite buildDesktop app buildRelease and payment pipelineSales partnerContact
ServicesRemote desktopCustom installer packages
TASTEDEV
Products

Desktop tools

TASTECADComplex drawings, opened with easeTASTEFILESJust the files you need, as fast as possibleTASTEFTPThe tidiest path for your filesTASTESSHA stronger link between you and your serversTASTEZIPPack faster, unpack saferTASTEWINMA keyboard-first file manager with two panes

Developer tools

TASTECODEEdit, build, debug and test Rust apps in one windowTASTESTUDIOFrom editing to remote tests and approved AI fixesTASTEETLMove data while you watch the values

Servers

TASTEREMOTEA remote desktop you run on your own serverTASTEGEORebuilding a GeoServer-compatible geospatial server in RustTASTEMAILTake back control of your email

Investing

TASTESTOCKStock auto-trading that follows the rules you set: when, and what

Get started

DownloadsLatest builds of every productDocsHow to use each productBuySubscriptions and perpetual licencesAll productsEvery product at a glance
All products
MarketplaceNews
Tech

News

Today's dev newsOfficial announcements on languages, frameworks, GitHub and AIDeveloper docsGuides to languages, frameworks and algorithms

Programming languages

RustTypeScriptJavaScriptPythonGoC#JavaCC++KotlinDart

Frameworks

Web front-end frameworksNext.jsReactVue.js · NuxtSvelteKitAngular
Server frameworksSpring BootDjangoFastAPIASP.NET CoreNestJS · Express
App & desktop frameworksTauriFlutterReact NativeElectron

Algorithms

Algorithm basicsComplexity analysis · Sorting · Searching · Basic data structures · Trees and heapsCore algorithmsGraph traversal · Shortest paths & minimum spanning trees · Dynamic programming · Greedy algorithms · Divide and conquer · BacktrackingAdvanced algorithmsString algorithms · Math and number theory · Bit manipulation · Segment trees · Union-findPractical algorithmsCoding interview strategy · LRU cache · Rate limiting · Consistent hashing
All development docs
Community
ProjectsDiscover builders and their workDevelopment logsDecisions and lessons learnedPromptsReusable instructionsAI tool issuesProblems and workarounds for Claude, Codex, GeminiShowcaseFinished resultsCommunity guideHow we build in the open
Work with us
Tech transferNative apps in Rust and eguiWebsite build10 languages, accounts, docs and downloadsDesktop app buildRust and egui, no WebViewRelease and payment pipelineSigning, MSI, deb, rpm, AppImage, hashesSales partnerRecommend us and earn 30%ContactBuilds, partnerships and investment
Services
Remote desktopReach your computer from a browserCustom installer packagesOnly the features you need, settings preloaded
Buy
EN
한국어EnglishDeutschEspañolFrançaisItalianoPortuguês (Brasil)日本語简体中文繁體中文
Log in
Log in
TASTEDEV

From small tools to better development.

support@tastedev.netSupport TASTEDEV
ProductsProduct lineupBuyDocsDownloadsMarketplaceSupport
CommunityProjectsDevelopment logsPromptsAI tool issuesShowcase
PoliciesAbout usPrivacy policyTerms of serviceSubscription termsRefund policyCommunity guidelines
AccountLog inSign up
Visitors
Today
Yesterday
Total views
Company
GXSOFT
Representative
CHOI YOUNG GU
Business registration number
853-44-00368
Address
9F V24, 351 Gyeongin-ro, Michuhol-gu, Incheon, Republic of Korea
Phone
+82-10-4404-1523
Email
whitecalvin@tastedev.net
Privacy officer
CHOI YOUNG GU

© 2026 TASTEDEVProduct information is based on verified development sources.Released · improving

Kotlin docs
Kotlin
Getting StartedSyntax BasicsTypes and DataModules and PackagesErrors and TestingKey Concepts
Discussions

Kotlin guide · 1/6

Getting Started

Kotlin is a statically typed language from JetBrains. It most often runs on the JVM, compiling to the same bytecode as Java, so every Java library is available to you. It is also the preferred language for Android and is used for backends and multiplatform projects. This chapter shows three ways to run your first program: the browser-based Playground, the command-line compiler, and a Gradle project in IntelliJ IDEA.

Try it in the browser

The Kotlin Playground runs code without installing anything. You can switch the compile target (JVM, JS, Wasm and others), pick a compiler version, and share snippets by link. It is all you need while learning the syntax.

fun main() {
    val name = "Kotlin"
    println("Hello, $name!")
}

fun main() is the entry point. There is no wrapper class and no semicolons, and println comes from the standard library, so no import is needed.

The command-line compiler

With a JDK installed, kotlinc compiles a single file. SDKMAN! or Homebrew are the easiest installers on macOS and Linux; on Windows, download the archive from the Kotlin GitHub releases page and add its bin folder to your PATH.

# install (pick one)
sdk install kotlin
brew install kotlin

# compile and run
kotlinc hello.kt -include-runtime -d hello.jar
java -jar hello.jar

-include-runtime bundles the Kotlin standard library into the JAR; without it, you would have to put the library on the classpath yourself. The bare compiler is great for understanding what happens under the hood, but real projects use a build tool.

IntelliJ IDEA

Since JetBrains created Kotlin, IntelliJ IDEA has the deepest support, and Kotlin tooling is included in the free edition. For Android work, use Android Studio, which is built on IntelliJ. To create a project:

  1. Choose New Project, then Kotlin as the language and Gradle as the build system.
  2. Select Kotlin as the Gradle DSL, so the build script is build.gradle.kts.
  3. Pick a JDK and click Create. A sample file appears under src/main/kotlin.
  4. Click the run icon in the gutter next to main.

A Gradle project with the Kotlin DSL

You can also scaffold a project from the terminal. gradle init asks questions interactively, or you can answer them up front with flags:

mkdir hello-kotlin && cd hello-kotlin
gradle init --type kotlin-application --dsl kotlin
./gradlew run

gradlew (gradlew.bat on Windows) is the Gradle Wrapper. It downloads the Gradle version pinned by the project, so everyone on the team builds with the same one. The generated build script looks roughly like this:

// app/build.gradle.kts
plugins {
    alias(libs.plugins.kotlin.jvm)
    application
}

repositories {
    mavenCentral()
}

dependencies {
    testImplementation(kotlin("test"))
}

application {
    mainClass.set("org.example.AppKt")
}

The Kotlin DSL lets you write build scripts in Kotlin itself. It does the same job as a Groovy build.gradle, but you get code completion and type checking in the IDE. The kotlin.jvm plugin compiles your sources, application adds the run task, and plugin and library versions live in the version catalog at gradle/libs.versions.toml.

Where main ends up

AppKt in mainClass is not a typo. On the JVM, top-level functions are compiled into static methods of a class named after the file plus Kt. So main in App.kt inside package org.example becomes org.example.AppKt.main.

// app/src/main/kotlin/org/example/App.kt
package org.example

fun main(args: Array<String>) {
    if (args.isEmpty()) {
        println("No arguments given")
    } else {
        println("First argument: ${args[0]}")
    }
}

Pass arguments with ./gradlew run --args="hello world". If you don't need them, a plain fun main() works too.

Summary

  • The Kotlin Playground lets you practice without installing anything.
  • kotlinc is handy for single-file experiments; Gradle is for real projects.
  • Start new projects with Gradle and the Kotlin DSL (build.gradle.kts) and run them with ./gradlew run.
  • A top-level main is the entry point, compiled on the JVM into a class named after the file plus Kt.
Questions about this chapter?
Next chapterSyntax Basics

0 comments

Top commentsNewest first

Sign in · Sign in to leave a comment.