---
title: "init(migratingFrom:to:)"
framework: coredata
role: symbol
role_heading: Initializer
path: "coredata/nscustommigrationstage/init(migratingfrom:to:)"
---

# init(migratingFrom:to:)

Creates a custom migration stage with the specified source and destination model references.

## Declaration

```swift
convenience init(migratingFrom currentModel: NSManagedObjectModelReference, to nextModel: NSManagedObjectModelReference)
```

## Parameters

- `currentModel`: The reference that represents the migration’s source model.
- `nextModel`: The reference that represents the migration’s destination model.

## See Also

### Creating a custom migration stage

- [NSManagedObjectModelReference](coredata/nsmanagedobjectmodelreference.md)
