Ktor Project Setup: embeddedServer and Application Modules
Bootstrap a Ktor application, configure Netty, and define application modules.
What Is Ktor?
Ktor is JetBrains' asynchronous Kotlin framework for building servers and clients. It is coroutine-first, plugin-based, and has no magic: every feature you need is explicitly installed. Ktor applications are plain Kotlin programs — no DI container required.
Adding Ktor Dependencies
Add the core server engine (Netty is the most common) and the core Ktor server library to your build.gradle.kts:
dependencies {
implementation("io.ktor:ktor-server-core:2.3.12")
implementation("io.ktor:ktor-server-netty:2.3.12")
implementation("ch.qos.logback:logback-classic:1.5.6") // logging
}All lessons in this course
- Ktor Project Setup: embeddedServer and Application Modules
- Routing and Typed Parameters
- Content Negotiation and kotlinx.serialization
- Authentication Plugins: JWT and Session