<!--
{
  "availability" : [
    "iOS: 16.0.0 -",
    "iPadOS: 16.0.0 -",
    "macCatalyst: 16.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "UIKit",
  "identifier" : "/documentation/UIKit/UISearchControllerDelegate/searchController(_:didChangeFrom:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "UIKit"
    ],
    "preciseIdentifier" : "c:objc(pl)UISearchControllerDelegate(im)searchController:didChangeFromSearchBarPlacement:"
  },
  "title" : "searchController(_:didChangeFrom:)"
}
-->

# searchController(_:didChangeFrom:)

Notifies the delegate after the search bar placement changes.

```
optional func searchController(_ searchController: UISearchController, didChangeFrom previousPlacement: UINavigationItem.SearchBarPlacement)
```

## Parameters

`searchController`

The search controller associated with the search bar.

`previousPlacement`

The previous search bar placement.

## Discussion

The system calls this method after a search bar placement change occurs. Implement this method if you need to make any custom changes to your search suggestions UI according to the previous search bar placement.

The system calls this method after [`searchController(_:willChangeTo:)`](/documentation/UIKit/UISearchControllerDelegate/searchController(_:willChangeTo:)).

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)