---
title: "Disable Automatic Photos Picker Dismissal | Explore SwiftUI"
description: "Prevents the Photos picker from dismissing automatically. Without this modifier, the Photos picker would automatically dismiss when an image is tapped"
canonical_url: "https://exploreswiftui.com/library/photospicker/disable-automatic-photos-picker-dismissal"
meta:
  author: "Explore SwiftUI"
  "og:description": "Prevents the Photos picker from dismissing automatically. Without this modifier, the Photos picker would automatically dismiss when an image is tapped"
  "og:image": "https://exploreswiftui.com/_og/d/c_Component%2Ctitle_Disable%2BAutomatic%2BPhotos%2BPicker%2BDismissal%2Cdescription_~UHJldmVudHMgdGhlIFBob3RvcyBwaWNrZXIgZnJvbSBkaXNtaXNzaW5nIGF1dG9tYXRpY2FsbHkuIFdpdGhvdXQgdGhpcyBtb2RpZmllciwgdGhlIFBob3RvcyBwaWNrZXIgd291bGQgYXV0b21hdGljYWxseSBkaXNtaXNzIHdoZW4gYW4gaW1hZ2UgaXMgdGFwcGVkLg%2Ccategory_PhotosPicker%2Cimage_~L2FwaS9pbWFnZXMvMjY0L3ZhcmlhbnRzLzIyMzE~dj0xNzk0OTEwNjY1NzY4JnI9MiZ3PTEyODAmcT04NSZmPWpwZWc%2CimageMode_crop%2CimagePosition_top%2CimageFrame_~cG9zaXRpb246IGFic29sdXRlOyByaWdodDogMDsgd2lkdGg6IDY0MHB4OyBoZWlnaHQ6IDQ4MHB4OyBkaXNwbGF5OiBmbGV4OyBvdmVyZmxvdzogaGlkZGVuOyBiYWNrZ3JvdW5kOiAjRkZGRkZGOyBib3gtc2hhZG93OiAwIC0xMHB4IDUwcHggcmdiYSgzNyw5OSwyMzUsMC4xOCk7IGJvcmRlci1sZWZ0OiAxcHggc29saWQgcmdiYSgwLDAsMCwwLjA2KTsgYm90dG9tOiAwOyBib3JkZXItdG9wOiAxcHggc29saWQgcmdiYSgwLDAsMCwwLjA2KTsgYm9yZGVyLXRvcC1sZWZ0LXJhZGl1czogNzRweDs%2Cprops_eyJwbGF0Zm9ybXMiOlsiaU9TIiwiaVBhZE9TIiwibWFjT1MiLCJ2aXNpb25PUyJdfQ%2Cp_Ii9saWJyYXJ5L3Bob3Rvc3BpY2tlci9kaXNhYmxlLWF1dG9tYXRpYy1waG90b3MtcGlja2VyLWRpc21pc3NhbCI%2Cs_LbZjmknDe6YtAcXf.png"
  "og:image:height": "630"
  "og:image:type": image/png
  "og:image:width": "1200"
  "og:title": "Disable Automatic Photos Picker Dismissal | Explore SwiftUI"
  "twitter:description": "Prevents the Photos picker from dismissing automatically. Without this modifier, the Photos picker would automatically dismiss when an image is tapped"
  "twitter:image": "https://exploreswiftui.com/_og/d/c_Component%2Ctitle_Disable%2BAutomatic%2BPhotos%2BPicker%2BDismissal%2Cdescription_~UHJldmVudHMgdGhlIFBob3RvcyBwaWNrZXIgZnJvbSBkaXNtaXNzaW5nIGF1dG9tYXRpY2FsbHkuIFdpdGhvdXQgdGhpcyBtb2RpZmllciwgdGhlIFBob3RvcyBwaWNrZXIgd291bGQgYXV0b21hdGljYWxseSBkaXNtaXNzIHdoZW4gYW4gaW1hZ2UgaXMgdGFwcGVkLg%2Ccategory_PhotosPicker%2Cimage_~L2FwaS9pbWFnZXMvMjY0L3ZhcmlhbnRzLzIyMzE~dj0xNzk0OTEwNjY1NzY4JnI9MiZ3PTEyODAmcT04NSZmPWpwZWc%2CimageMode_crop%2CimagePosition_top%2CimageFrame_~cG9zaXRpb246IGFic29sdXRlOyByaWdodDogMDsgd2lkdGg6IDY0MHB4OyBoZWlnaHQ6IDQ4MHB4OyBkaXNwbGF5OiBmbGV4OyBvdmVyZmxvdzogaGlkZGVuOyBiYWNrZ3JvdW5kOiAjRkZGRkZGOyBib3gtc2hhZG93OiAwIC0xMHB4IDUwcHggcmdiYSgzNyw5OSwyMzUsMC4xOCk7IGJvcmRlci1sZWZ0OiAxcHggc29saWQgcmdiYSgwLDAsMCwwLjA2KTsgYm90dG9tOiAwOyBib3JkZXItdG9wOiAxcHggc29saWQgcmdiYSgwLDAsMCwwLjA2KTsgYm9yZGVyLXRvcC1sZWZ0LXJhZGl1czogNzRweDs%2Cprops_eyJwbGF0Zm9ybXMiOlsiaU9TIiwiaVBhZE9TIiwibWFjT1MiLCJ2aXNpb25PUyJdfQ%2Cp_Ii9saWJyYXJ5L3Bob3Rvc3BpY2tlci9kaXNhYmxlLWF1dG9tYXRpYy1waG90b3MtcGlja2VyLWRpc21pc3NhbCI%2Cs_LbZjmknDe6YtAcXf.png"
  "twitter:title": "Disable Automatic Photos Picker Dismissal | Explore SwiftUI"
---

> Index of every page on this site: [llms.txt](https://exploreswiftui.com/llms.txt)

**Interactive previews**[ iPhone](https://exploreswiftui.com/iphone?element=264)

# **Disable Automatic Photos Picker Dismissal**

Prevents the Photos picker from dismissing automatically. Without this modifier, the Photos picker would automatically dismiss when an image is tapped.

![Disable Automatic Photos Picker Dismissal - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/264/variants/2231?v=1794910665768&r=2&w=800&q=80&f=webp)

### **Platform Compatibility**

iOS 27.3+ iPadOS 27.3+ macOS 27.3+ visionOS 27.3+

### **Tags**

### **SwiftUI Code**

[ Docs](<https://developer.apple.com/documentation/SwiftUI/View/photosPickerAutomaticDismissDisabled(_:)>)

```
@State private var selectedPhoto: PhotosPickerItem?

var body: some View {
    PhotosPicker("FooBar", selection: $selectedPhoto)
        .photosPickerAutomaticDismissDisabled()
}
```

### **Found an issue or have a suggestion?**

Created: November 17, 2026Updated: November 17, 2026

### **More PhotosPicker Components **

[**View all **](https://exploreswiftui.com/library/photospicker)

![Photos Picker - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/271/variants/2279?v=1794914000934&r=2&w=412&q=75&f=webp)

### **Photos Picker**

Creates a picker with a title key and selection, and optionally configures the types of items to show and item encoding behavior.

![Photos Picker Title - iPadOS - Landscape - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/270/variants/2261?v=1794910543223&r=2&w=412&q=75&f=webp)

### **Photos Picker Title**

Overrides the title of the Photos picker. The title is not visible on small screens, like the iPhone.

![Photos Picker Prompt - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/269/variants/2259?v=1794910719258&r=2&w=412&q=75&f=webp)

### **Photos Picker Prompt**

Sets the prompt of the Photos picker.

![On Secondary Photos Picker Action - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/268/variants/2255?v=1794910758520&r=2&w=412&q=75&f=webp)

### **On Secondary Photos Picker Action**

Sets the secondary action handler for the Photos picker.

![On Primary Photos Picker Action - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/267/variants/2251?v=1794910789851&r=2&w=412&q=75&f=webp)

### **On Primary Photos Picker Action**

Sets the primary action handler for the Photos picker.

![Container Photo Picker - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/266/variants/2243?v=1794910698423&r=2&w=412&q=75&f=webp)

### **Container Photo Picker**

Limits the Photos picker to only show items in the specified container. In this case, to the user-created album "CustomAlbum".

![Custom Photo Picker Buttons - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/265/variants/2235?v=1794910823065&r=2&w=412&q=75&f=webp)

### **Custom Photo Picker Buttons**

Sets the primary and secondary button types of the Photos picker.

![Range Photo Picker - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/263/variants/2229?v=1794910645062&r=2&w=412&q=75&f=webp)

### **Range Photo Picker**

Presents a Photos picker that selects a collection of PhotosPickerItem, constrained to a range of selection counts.

### **Explore Other Components **

[**Browse all **](https://exploreswiftui.com/)

![Content Unavailable Search Text - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/3/variants/10?v=1790073478842&r=2&w=412&q=75&f=webp)

### **Content Unavailable Search Text**

A pre-built placeholder for empty search results with search text

![Glass Effect Container - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/96/variants/377?v=1794863958859&r=2&w=412&q=75&f=webp)

### **Glass Effect Container**

A view that combines multiple Liquid Glass shapes into a single shape that can morph individual shapes into one another

![Value Tab View - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/165/variants/616?v=1790073478842&r=2&w=412&q=75&f=webp)

### **Value Tab View**

Creates a tab view that uses a builder to create and specify selection values for its tabs.

![RenameButton - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/37/variants/213?v=1790073478842&r=2&w=412&q=75&f=webp)

### **RenameButton**

A button that triggers a standard rename action

![Subscription Store View - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/225/variants/531?v=1792441754239&r=2&w=412&q=75&f=webp)

### **Subscription Store View**

Creates a view that loads subscriptions based on a collection of product identifiers, and merchandises them with automatic marketing content.

![PasteButton - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/35/variants/235?v=1790073478842&r=2&w=412&q=75&f=webp)

### **PasteButton**

A system button that reads items from the pasteboard and delivers it to a closure.

![Hide Tab Bar On Scroll Down - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/88/variants/383?v=1790073478842&r=2&w=412&q=75&f=webp)

### **Hide Tab Bar On Scroll Down**

Minimize the tab bar when downwards scrolling starts. Minimizing is supported for tab bars on only iPhone

![Disclosure Group - iOS on iPhone - Portrait - Flat Design - Light Mode - Preview](https://exploreswiftui.com/api/images/131/variants/363?v=1790073478842&r=2&w=412&q=75&f=webp)

### **Disclosure Group**

A view that shows or hides another content view, based on the state of a disclosure control.

```json
{"@context":"https://schema.org","@graph":[{"@id":"https://exploreswiftui.com/#website","@type":"WebSite","description":"A visual library for SwiftUI APIs, components, and modifiers","inLanguage":"en-US","name":"Explore SwiftUI","url":"https://exploreswiftui.com/","publisher":{"@id":"https://exploreswiftui.com/#identity"}},{"@id":"https://exploreswiftui.com/library/photospicker/disable-automatic-photos-picker-dismissal#webpage","@type":"WebPage","dateModified":"2026-11-17T10:17:45.947Z","datePublished":"2026-11-17T08:54:57.888Z","description":"Prevents the Photos picker from dismissing automatically. Without this modifier, the Photos picker would automatically dismiss when an image is tapped","name":"Disable Automatic Photos Picker Dismissal","url":"https://exploreswiftui.com/library/photospicker/disable-automatic-photos-picker-dismissal","breadcrumb":{"@id":"https://exploreswiftui.com/library/photospicker/disable-automatic-photos-picker-dismissal#breadcrumb"},"isPartOf":{"@id":"https://exploreswiftui.com/#website"},"mainEntity":{"@id":"https://exploreswiftui.com/library/photospicker/disable-automatic-photos-picker-dismissal#article"},"potentialAction":[{"@type":"ReadAction","target":["https://exploreswiftui.com/library/photospicker/disable-automatic-photos-picker-dismissal"]}],"primaryImageOfPage":{"@id":"https://exploreswiftui.com/#logo"}},{"@id":"https://exploreswiftui.com/#identity","@type":"Organization","description":"A visual library for SwiftUI APIs, components, and modifiers","name":"Explore SwiftUI","url":"https://exploreswiftui.com","logo":{"@id":"https://exploreswiftui.com/#logo"},"sameAs":["https://x.com/Typ0genius","https://mastodon.social/@Typ0genius"]},{"@id":"https://exploreswiftui.com/library/photospicker/disable-automatic-photos-picker-dismissal#article","citation":"https://developer.apple.com/documentation/SwiftUI/View/photosPickerAutomaticDismissDisabled(_:)","dateModified":"2026-11-17T10:17:45.947Z","datePublished":"2026-11-17T08:54:57.888Z","description":"Prevents the Photos picker from dismissing automatically. Without this modifier, the Photos picker would automatically dismiss when an image is tapped","headline":"Disable Automatic Photos Picker Dismissal","inLanguage":"en-US","name":"Disable Automatic Photos Picker Dismissal","thumbnailUrl":"https://exploreswiftui.com/api/images/264/variants/2231?v=1794910665768&r=2","url":"https://exploreswiftui.com/library/photospicker/disable-automatic-photos-picker-dismissal","@type":["Article","TechArticle"],"about":{"@type":"Thing","name":"SwiftUI"},"author":{"@id":"https://exploreswiftui.com/#identity"},"hasPart":{"@id":"https://exploreswiftui.com/library/photospicker/disable-automatic-photos-picker-dismissal#source-code"},"image":{"@id":"https://exploreswiftui.com/#/schema/image/1"},"isPartOf":{"@id":"https://exploreswiftui.com/library/photospicker/disable-automatic-photos-picker-dismissal#webpage"},"mainEntityOfPage":{"@id":"https://exploreswiftui.com/library/photospicker/disable-automatic-photos-picker-dismissal#webpage"},"publisher":{"@id":"https://exploreswiftui.com/#identity"}},{"@id":"https://exploreswiftui.com/library/photospicker/disable-automatic-photos-picker-dismissal#source-code","@type":"SoftwareSourceCode","codeSampleType":"full example","description":"Prevents the Photos picker from dismissing automatically. Without this modifier, the Photos picker would automatically dismiss when an image is tapped","name":"Disable Automatic Photos Picker Dismissal SwiftUI Example","programmingLanguage":"Swift","runtimePlatform":"SwiftUI","text":"@State private var selectedPhoto: PhotosPickerItem?\n\nvar body: some View {\n    PhotosPicker(\"FooBar\", selection: $selectedPhoto)\n        .photosPickerAutomaticDismissDisabled()\n}","about":[{"@type":"Thing","name":"SwiftUI"},{"@type":"Thing","name":"PhotosPicker"},{"@type":"Thing","name":"Disable Automatic Photos Picker Dismissal"}]},{"@id":"https://exploreswiftui.com/library/photospicker/disable-automatic-photos-picker-dismissal#breadcrumb","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","name":"Home","item":"https://exploreswiftui.com","position":1},{"@type":"ListItem","name":"PhotosPicker","item":"https://exploreswiftui.com/library/photospicker","position":2},{"@type":"ListItem","name":"Disable Automatic Photos Picker Dismissal","item":"https://exploreswiftui.com/library/photospicker/disable-automatic-photos-picker-dismissal","position":3}]},{"@id":"https://exploreswiftui.com/#logo","@type":"ImageObject","caption":"Explore SwiftUI","contentUrl":"https://exploreswiftui.com/apple-touch-icon.png","inLanguage":"en","url":"https://exploreswiftui.com/apple-touch-icon.png"},{"@id":"https://exploreswiftui.com/#/schema/image/1","@type":"ImageObject","contentUrl":"https://exploreswiftui.com/api/images/264/variants/2231?v=1794910665768&r=2","inLanguage":"en","url":"https://exploreswiftui.com/api/images/264/variants/2231?v=1794910665768&r=2"}]}
```