Find the Document Directory of your iOS app

Jul 3, 2022 1 min read
Find the Document Directory of your iOS app

We can find the document directory in the following ways:

iOS 16+

let documentDirectory = URL.documentsDirectory
print("App's document directory: \(documentDirectory)")

You would get something like:

For older iOS versions you can use:

print(FileManager.default.urls(for: .documentDirectory, in: .userDomainMask).first!.path)
Great! Next, complete checkout for full access to ArturoFM.
Welcome back! You've successfully signed in.
You've successfully subscribed to ArturoFM.
Success! Your account is fully activated, you now have access to all content.
Success! Your billing info has been updated.
Your billing was not updated.