# Data classes in Kotlin

DevFeed: [Data classes in Kotlin](<https://devfeed.tech/articles/data-classes-in-kotlin-39329.md>)

Original publisher: [Read original article](<https://kt.academy/article/kfde-data>)

Published: 2023-11-13T00:01:00Z

Content type: tutorial

Language: en

Sources: [Kt. Academy](<https://devfeed.tech/sources/kt-academy.md>)

Topics: [Kotlin](<https://devfeed.tech/topics/kotlin.md>), [classes](<https://devfeed.tech/topics/classes.md>), [data](<https://devfeed.tech/topics/data.md>)

Tags: [classes](<https://devfeed.tech/tags/classes.md>), [code](<https://devfeed.tech/tags/code.md>), [data-class](<https://devfeed.tech/tags/data-class.md>), [kotlin](<https://devfeed.tech/tags/kotlin.md>), [type](<https://devfeed.tech/tags/type.md>), [workshop-learning-programming](<https://devfeed.tech/tags/workshop-learning-programming.md>)

## AI overview

This tutorial explains Kotlin data classes, including how they differ from regular classes and how the compiler generates methods such as equals, hashCode, toString, and component functions. It also discusses inherited object behavior and when custom overrides are typically unnecessary.

## Source excerpt

What are data classes in Kotlin and how do we use them.