---
title: keySpace
framework: avfoundation
role: symbol
role_heading: Instance Property
path: avfoundation/avmetadataitem/keyspace
---

# keySpace

The key space for the metadata item’s key.

## Declaration

```swift
var keySpace: AVMetadataKeySpace? { get }
```

## Discussion

Discussion The key space that this property value specifies is typically the default key space for the metadata container that stores the metadata item. AVFoundation uses key spaces to group related sets of keys. For example, the framework defines different key spaces for common keys, iTunes keys, ID3 keys, and QuickTime keys. Key spaces aid in filtering arrays of metadata items.

## See Also

### Accessing keys and key spaces

- [key](avfoundation/avmetadataitem/key.md)
- [commonKey](avfoundation/avmetadataitem/commonkey.md)
