---
title: "replaceAll(searchQuery:replacementString:options:)"
framework: uikit
role: symbol
role_heading: Instance Method
path: "uikit/uifindsession/replaceall(searchquery:replacementstring:options:)"
---

# replaceAll(searchQuery:replacementString:options:)

Replaces all matching instances of the query string with the replacement string you provide.

## Declaration

```swift
func replaceAll(searchQuery: String, replacementString: String, options: UITextSearchOptions?)
```

## Parameters

- `searchQuery`: The string to search for and replace, the user provides through the search text field of the system find panel.
- `replacementString`: The replacement string, the user provides through the replace text field of the system find panel.
- `options`: The object containing all the configurable options for the search.

## See Also

### Managing session interactions

- [performSearch(query:options:)](uikit/uifindsession/performsearch(query:options:).md)
- [performSingleReplacement(query:replacementString:options:)](uikit/uifindsession/performsinglereplacement(query:replacementstring:options:).md)
- [highlightNextResult(in:)](uikit/uifindsession/highlightnextresult(in:).md)
- [invalidateFoundResults()](uikit/uifindsession/invalidatefoundresults().md)
