---
title: "placeholderURL(for:)"
framework: fileprovider
role: symbol
role_heading: Type Method
path: "fileprovider/nsfileproviderextension/placeholderurl(for:)"
---

# placeholderURL(for:)

Returns a placeholder URL for a given document URL.

## Declaration

```swift
class func placeholderURL(for url: URL) -> URL
```

## Parameters

- `url`: The document URL to be converted.

## Return Value

Return Value A placeholder URL for the given document.

## Discussion

Discussion This method maps file URLs into their corresponding placeholder URLs. You typically call this method to generate the placeholder URL before calling writePlaceholder(at:withMetadata:). You must not override this method.

## See Also

### Managing placeholders

- [writePlaceholder(at:withMetadata:)](fileprovider/nsfileproviderextension/writeplaceholder(at:withmetadata:).md)
