What is object keyword in Kotlin?

Updated May 16, 2026

Short answer

Used for singletons and anonymous objects.

Deep explanation

Object declarations create singleton instances in Kotlin.

Real-world example

Logging utilities in apps.

Common mistakes

  • Using object when DI is better.

Follow-up questions

  • What is companion object?
  • Is object thread-safe?

More Kotlin interview questions

View all →