A data class is a Kotlin class meant to hold data. The compiler generates equals/hashCode, toString, copy() and componentN functions automatically, making it ideal for DTOs and value objects.