---
title: URLResourceKey
framework: foundation
role: symbol
role_heading: Structure
path: foundation/urlresourcekey
---

# URLResourceKey

Keys that apply to file system URLs.

## Declaration

```swift
struct URLResourceKey
```

## Discussion

Discussion To request information using one of these keys, pass it to the forKey: parameter of the getResourceValue(_:forKey:) instance method.

## Topics

### Application keys

- [isApplicationKey](foundation/urlresourcekey/isapplicationkey.md)
- [applicationIsScriptableKey](foundation/urlresourcekey/applicationisscriptablekey.md)

### Directory keys

- [isDirectoryKey](foundation/urlresourcekey/isdirectorykey.md)
- [parentDirectoryURLKey](foundation/urlresourcekey/parentdirectoryurlkey.md)
- [directoryEntryCountKey](foundation/urlresourcekey/directoryentrycountkey.md)

### File keys

- [fileAllocatedSizeKey](foundation/urlresourcekey/fileallocatedsizekey.md)
- [fileProtectionKey](foundation/urlresourcekey/fileprotectionkey.md)
- [URLFileProtection](foundation/urlfileprotection.md)
- [fileContentIdentifierKey](foundation/urlresourcekey/filecontentidentifierkey.md)
- [fileResourceIdentifierKey](foundation/urlresourcekey/fileresourceidentifierkey.md)
- [fileResourceTypeKey](foundation/urlresourcekey/fileresourcetypekey.md)
- [URLFileResourceType](foundation/urlfileresourcetype.md)
- [fileSecurityKey](foundation/urlresourcekey/filesecuritykey.md)
- [fileSizeKey](foundation/urlresourcekey/filesizekey.md)
- [isAliasFileKey](foundation/urlresourcekey/isaliasfilekey.md)
- [isPackageKey](foundation/urlresourcekey/ispackagekey.md)
- [isRegularFileKey](foundation/urlresourcekey/isregularfilekey.md)
- [isPurgeableKey](foundation/urlresourcekey/ispurgeablekey.md)
- [isSparseKey](foundation/urlresourcekey/issparsekey.md)
- [mayHaveExtendedAttributesKey](foundation/urlresourcekey/mayhaveextendedattributeskey.md)
- [mayShareFileContentKey](foundation/urlresourcekey/maysharefilecontentkey.md)
- [preferredIOBlockSizeKey](foundation/urlresourcekey/preferredioblocksizekey.md)
- [totalFileAllocatedSizeKey](foundation/urlresourcekey/totalfileallocatedsizekey.md)
- [totalFileSizeKey](foundation/urlresourcekey/totalfilesizekey.md)
- [fileIdentifierKey](foundation/urlresourcekey/fileidentifierkey.md)

### Volume capacity keys

- [Checking Volume Storage Capacity](foundation/checking-volume-storage-capacity.md)
- [volumeAvailableCapacityKey](foundation/urlresourcekey/volumeavailablecapacitykey.md)
- [volumeAvailableCapacityForImportantUsageKey](foundation/urlresourcekey/volumeavailablecapacityforimportantusagekey.md)
- [volumeAvailableCapacityForOpportunisticUsageKey](foundation/urlresourcekey/volumeavailablecapacityforopportunisticusagekey.md)
- [volumeTotalCapacityKey](foundation/urlresourcekey/volumetotalcapacitykey.md)

### Volume status keys

- [volumeIsAutomountedKey](foundation/urlresourcekey/volumeisautomountedkey.md)
- [volumeIsBrowsableKey](foundation/urlresourcekey/volumeisbrowsablekey.md)
- [volumeIsEjectableKey](foundation/urlresourcekey/volumeisejectablekey.md)
- [volumeIsEncryptedKey](foundation/urlresourcekey/volumeisencryptedkey.md)
- [volumeIsInternalKey](foundation/urlresourcekey/volumeisinternalkey.md)
- [volumeIsJournalingKey](foundation/urlresourcekey/volumeisjournalingkey.md)
- [volumeIsLocalKey](foundation/urlresourcekey/volumeislocalkey.md)
- [volumeIsReadOnlyKey](foundation/urlresourcekey/volumeisreadonlykey.md)
- [volumeIsRemovableKey](foundation/urlresourcekey/volumeisremovablekey.md)
- [volumeIsRootFileSystemKey](foundation/urlresourcekey/volumeisrootfilesystemkey.md)
- [volumeSupportsFileProtectionKey](foundation/urlresourcekey/volumesupportsfileprotectionkey.md)
- [volumeTypeNameKey](foundation/urlresourcekey/volumetypenamekey.md)
- [volumeSubtypeKey](foundation/urlresourcekey/volumesubtypekey.md)
- [volumeMountFromLocationKey](foundation/urlresourcekey/volumemountfromlocationkey.md)

### Volume support keys

- [isMountTriggerKey](foundation/urlresourcekey/ismounttriggerkey.md)
- [isVolumeKey](foundation/urlresourcekey/isvolumekey.md)
- [volumeCreationDateKey](foundation/urlresourcekey/volumecreationdatekey.md)
- [volumeIdentifierKey](foundation/urlresourcekey/volumeidentifierkey.md)
- [volumeLocalizedFormatDescriptionKey](foundation/urlresourcekey/volumelocalizedformatdescriptionkey.md)
- [volumeLocalizedNameKey](foundation/urlresourcekey/volumelocalizednamekey.md)
- [volumeMaximumFileSizeKey](foundation/urlresourcekey/volumemaximumfilesizekey.md)
- [volumeNameKey](foundation/urlresourcekey/volumenamekey.md)
- [volumeResourceCountKey](foundation/urlresourcekey/volumeresourcecountkey.md)
- [volumeSupportsAccessPermissionsKey](foundation/urlresourcekey/volumesupportsaccesspermissionskey.md)
- [volumeSupportsAdvisoryFileLockingKey](foundation/urlresourcekey/volumesupportsadvisoryfilelockingkey.md)
- [volumeSupportsCasePreservedNamesKey](foundation/urlresourcekey/volumesupportscasepreservednameskey.md)
- [volumeSupportsCaseSensitiveNamesKey](foundation/urlresourcekey/volumesupportscasesensitivenameskey.md)
- [volumeSupportsCompressionKey](foundation/urlresourcekey/volumesupportscompressionkey.md)
- [volumeSupportsExclusiveRenamingKey](foundation/urlresourcekey/volumesupportsexclusiverenamingkey.md)
- [volumeSupportsExtendedSecurityKey](foundation/urlresourcekey/volumesupportsextendedsecuritykey.md)
- [volumeSupportsFileCloningKey](foundation/urlresourcekey/volumesupportsfilecloningkey.md)
- [volumeSupportsHardLinksKey](foundation/urlresourcekey/volumesupportshardlinkskey.md)
- [volumeSupportsImmutableFilesKey](foundation/urlresourcekey/volumesupportsimmutablefileskey.md)
- [volumeSupportsJournalingKey](foundation/urlresourcekey/volumesupportsjournalingkey.md)
- [volumeSupportsPersistentIDsKey](foundation/urlresourcekey/volumesupportspersistentidskey.md)
- [volumeSupportsRenamingKey](foundation/urlresourcekey/volumesupportsrenamingkey.md)
- [volumeSupportsRootDirectoryDatesKey](foundation/urlresourcekey/volumesupportsrootdirectorydateskey.md)
- [volumeSupportsSparseFilesKey](foundation/urlresourcekey/volumesupportssparsefileskey.md)
- [volumeSupportsSwapRenamingKey](foundation/urlresourcekey/volumesupportsswaprenamingkey.md)
- [volumeSupportsSymbolicLinksKey](foundation/urlresourcekey/volumesupportssymboliclinkskey.md)
- [volumeSupportsVolumeSizesKey](foundation/urlresourcekey/volumesupportsvolumesizeskey.md)
- [volumeSupportsZeroRunsKey](foundation/urlresourcekey/volumesupportszerorunskey.md)
- [volumeURLForRemountingKey](foundation/urlresourcekey/volumeurlforremountingkey.md)
- [volumeURLKey](foundation/urlresourcekey/volumeurlkey.md)
- [volumeUUIDStringKey](foundation/urlresourcekey/volumeuuidstringkey.md)

### Ubiquitous keys

- [isUbiquitousItemKey](foundation/urlresourcekey/isubiquitousitemkey.md)
- [ubiquitousSharedItemMostRecentEditorNameComponentsKey](foundation/urlresourcekey/ubiquitousshareditemmostrecenteditornamecomponentskey.md)
- [ubiquitousItemDownloadRequestedKey](foundation/urlresourcekey/ubiquitousitemdownloadrequestedkey.md)
- [ubiquitousItemIsDownloadingKey](foundation/urlresourcekey/ubiquitousitemisdownloadingkey.md)
- [ubiquitousItemDownloadingErrorKey](foundation/urlresourcekey/ubiquitousitemdownloadingerrorkey.md)
- [ubiquitousItemDownloadingStatusKey](foundation/urlresourcekey/ubiquitousitemdownloadingstatuskey.md)
- [URLUbiquitousItemDownloadingStatus](foundation/urlubiquitousitemdownloadingstatus.md)
- [ubiquitousItemIsExcludedFromSyncKey](foundation/urlresourcekey/ubiquitousitemisexcludedfromsynckey.md)
- [ubiquitousItemIsUploadedKey](foundation/urlresourcekey/ubiquitousitemisuploadedkey.md)
- [ubiquitousItemIsUploadingKey](foundation/urlresourcekey/ubiquitousitemisuploadingkey.md)
- [ubiquitousItemUploadingErrorKey](foundation/urlresourcekey/ubiquitousitemuploadingerrorkey.md)
- [ubiquitousItemHasUnresolvedConflictsKey](foundation/urlresourcekey/ubiquitousitemhasunresolvedconflictskey.md)
- [ubiquitousItemContainerDisplayNameKey](foundation/urlresourcekey/ubiquitousitemcontainerdisplaynamekey.md)
- [ubiquitousSharedItemOwnerNameComponentsKey](foundation/urlresourcekey/ubiquitousshareditemownernamecomponentskey.md)
- [ubiquitousSharedItemCurrentUserPermissionsKey](foundation/urlresourcekey/ubiquitousshareditemcurrentuserpermissionskey.md)
- [ubiquitousSharedItemCurrentUserRoleKey](foundation/urlresourcekey/ubiquitousshareditemcurrentuserrolekey.md)
- [ubiquitousItemIsSharedKey](foundation/urlresourcekey/ubiquitousitemissharedkey.md)
- [URLUbiquitousSharedItemRole](foundation/urlubiquitousshareditemrole.md)
- [URLUbiquitousSharedItemPermissions](foundation/urlubiquitousshareditempermissions.md)
- [ubiquitousItemIsSyncPausedKey](foundation/urlresourcekey/ubiquitousitemissyncpausedkey.md)
- [ubiquitousItemSupportedSyncControlsKey](foundation/urlresourcekey/ubiquitousitemsupportedsynccontrolskey.md)

### Thumbnail keys

- [thumbnailKey](foundation/urlresourcekey/thumbnailkey.md)
- [thumbnailDictionaryKey](foundation/urlresourcekey/thumbnaildictionarykey.md)
- [URLThumbnailDictionaryItem](foundation/urlthumbnaildictionaryitem.md)

### Other resource keys

- [keysOfUnsetValuesKey](foundation/urlresourcekey/keysofunsetvalueskey.md)
- [quarantinePropertiesKey](foundation/urlresourcekey/quarantinepropertieskey.md)
- [addedToDirectoryDateKey](foundation/urlresourcekey/addedtodirectorydatekey.md)
- [attributeModificationDateKey](foundation/urlresourcekey/attributemodificationdatekey.md)
- [contentAccessDateKey](foundation/urlresourcekey/contentaccessdatekey.md)
- [contentModificationDateKey](foundation/urlresourcekey/contentmodificationdatekey.md)
- [creationDateKey](foundation/urlresourcekey/creationdatekey.md)
- [customIconKey](foundation/urlresourcekey/customiconkey.md)
- [documentIdentifierKey](foundation/urlresourcekey/documentidentifierkey.md)
- [effectiveIconKey](foundation/urlresourcekey/effectiveiconkey.md)
- [generationIdentifierKey](foundation/urlresourcekey/generationidentifierkey.md)
- [hasHiddenExtensionKey](foundation/urlresourcekey/hashiddenextensionkey.md)
- [isExcludedFromBackupKey](foundation/urlresourcekey/isexcludedfrombackupkey.md)
- [isExecutableKey](foundation/urlresourcekey/isexecutablekey.md)
- [isHiddenKey](foundation/urlresourcekey/ishiddenkey.md)
- [isReadableKey](foundation/urlresourcekey/isreadablekey.md)
- [isSymbolicLinkKey](foundation/urlresourcekey/issymboliclinkkey.md)
- [isSystemImmutableKey](foundation/urlresourcekey/issystemimmutablekey.md)
- [isUserImmutableKey](foundation/urlresourcekey/isuserimmutablekey.md)
- [isWritableKey](foundation/urlresourcekey/iswritablekey.md)
- [labelColorKey](foundation/urlresourcekey/labelcolorkey.md)
- [labelNumberKey](foundation/urlresourcekey/labelnumberkey.md)
- [linkCountKey](foundation/urlresourcekey/linkcountkey.md)
- [localizedLabelKey](foundation/urlresourcekey/localizedlabelkey.md)
- [localizedNameKey](foundation/urlresourcekey/localizednamekey.md)
- [localizedTypeDescriptionKey](foundation/urlresourcekey/localizedtypedescriptionkey.md)
- [nameKey](foundation/urlresourcekey/namekey.md)
- [pathKey](foundation/urlresourcekey/pathkey.md)
- [canonicalPathKey](foundation/urlresourcekey/canonicalpathkey.md)
- [tagNamesKey](foundation/urlresourcekey/tagnameskey.md)
- [typeIdentifierKey](foundation/urlresourcekey/typeidentifierkey.md)
- [contentTypeKey](foundation/urlresourcekey/contenttypekey.md)

### Initializers

- [init(_:)](foundation/urlresourcekey/init(_:).md)
- [init(rawValue:)](foundation/urlresourcekey/init(rawvalue:).md)

### Deprecated

- [ubiquitousItemIsDownloadedKey](foundation/urlresourcekey/ubiquitousitemisdownloadedkey.md)
- [ubiquitousItemPercentDownloadedKey](foundation/urlresourcekey/ubiquitousitempercentdownloadedkey.md)
- [ubiquitousItemPercentUploadedKey](foundation/urlresourcekey/ubiquitousitempercentuploadedkey.md)

## Relationships

### Conforms To

- [Equatable](swift/equatable.md)
- [Hashable](swift/hashable.md)
- [RawRepresentable](swift/rawrepresentable.md)
- [Sendable](swift/sendable.md)
- [SendableMetatype](swift/sendablemetatype.md)

## See Also

### Accessing Resource Values

- [resourceValues(forKeys:)](foundation/nsurl/resourcevalues(forkeys:).md)
- [getResourceValue(_:forKey:)](foundation/nsurl/getresourcevalue(_:forkey:).md)
- [setResourceValue(_:forKey:)](foundation/nsurl/setresourcevalue(_:forkey:).md)
- [setResourceValues(_:)](foundation/nsurl/setresourcevalues(_:).md)
- [removeAllCachedResourceValues()](foundation/nsurl/removeallcachedresourcevalues().md)
- [removeCachedResourceValue(forKey:)](foundation/nsurl/removecachedresourcevalue(forkey:).md)
- [setTemporaryResourceValue(_:forKey:)](foundation/nsurl/settemporaryresourcevalue(_:forkey:).md)
