Best way to migrate custom Archetype -> Dexterity types while maintaining the ID and UID

Hello everybody,

we have in our system AT based contents with custom UID reference fields.

These fields hold only the target object UID as a string, and the field maintains back references etc. in the annotation storage.

We would like to migrate these contents to dexterity, but of course it would be best to maintain the UID and the ID of the object to reduce the reference resolving steps in the migration.

I have seen that there lives some code for migration in Products.contentmigration and

Since I probably need to do the whole migration manually, I just wanted to know which would be the best starting point to do so, or if you could share some best practices with me how to achieve this the best way?

Many thanks in advance

Hey Ramon,

maybe this post could help you:

Also I guess the egg "" does something similar in the file "".

1 Like

@ramonski see the docs at

In are a couple of examples where I migrated 22 custom archetypes types to dexterity. uuids, ids, annotations, portlets etc. pp. are all kept with this method.

If you also need to migrate relations from relationfields you should look at