---
title: "addPersistentStore(with:completionHandler:)"
framework: coredata
role: symbol
role_heading: Instance Method
path: "coredata/nspersistentstorecoordinator/addpersistentstore(with:completionhandler:)"
---

# addPersistentStore(with:completionHandler:)

Adds a persistent store using the provided description.

## Declaration

```swift
func addPersistentStore(with storeDescription: NSPersistentStoreDescription, completionHandler block: @escaping (NSPersistentStoreDescription, (any Error)?) -> Void)
```

## Parameters

- `storeDescription`: A description object used to create and load a persistent store.
- `block`: The completion handler block that’s invoked after the store is added.

## See Also

### Adding or removing a store

- [addPersistentStore(type:configuration:at:options:)](coredata/nspersistentstorecoordinator/addpersistentstore(type:configuration:at:options:).md)
- [addPersistentStore(ofType:configurationName:at:options:)](coredata/nspersistentstorecoordinator/addpersistentstore(oftype:configurationname:at:options:).md)
- [remove(_:)](coredata/nspersistentstorecoordinator/remove(_:).md)
