Thanks for making this post. I've been trying to get SwiftData custom migration work with CloudKit for more than a week now and it seems to me it's not compatible with CloudKit (works fine with just SwiftData, but with CloudKit the willMigrate and didMigrate are never called). Better to use custom code I guess to change user data.