How to make @Parcelize work in Android Studio Quail 3 2026.1.3 Patch 1 Empty Template
07:55 21 Aug 2026

I was having trouble getting @Parcelize to work in my project the way it apparently does in examples all over the internet, so I created a brand new "empty template" just to test this. I added one Kotlin file:

package test.test.testparceling

import android.os.Parcelable

@Parcelize
data class City(val name: String, val country: String) : Parcelable

The editor cannot resolve (or compile) @Parcelize. Clearly there must be something that needs to be added to one or more of the project configuration files. I've tried various suggestions from various web searches; none of them worked. I assume there's been some sort of recent change in something such that the old answers on the internet no longer work, but I haven't found any explanation I understand. (I'm pretty new to Android programming and do not yet really understand Gradle or the build.gradle.kts and libs.versions.toml files; reading up on that is on my to-do list - but doesn't seem like it should be necessary in order to use such basic functionality.)

What do I need to add to what to make this work?

Thanks so much!

android gradle