---
title: "init(forIdentifier:)"
framework: webkit
role: symbol
role_heading: Initializer
path: "webkit/wkwebsitedatastore/init(foridentifier:)"
---

# init(forIdentifier:)

Returns the persistent data store with the unique identifier you provide.

## Declaration

```swift
init(forIdentifier identifier: UUID)
```

## Parameters

- `identifier`: An identifier that uniquely identifies a data store.

## Discussion

Discussion If the data store for the unique identifier you provide does not exist, the system creates and returns it. Use this method to get a data store for a profile. This method throws an exception if the identifier is not valid.

## See Also

### Creating a data store object

- [default()](webkit/wkwebsitedatastore/default().md)
- [nonPersistent()](webkit/wkwebsitedatastore/nonpersistent().md)
