---
title: "ignoresSafeArea(_:edges:)"
framework: swiftui
role: symbol
role_heading: Instance Method
path: "swiftui/view/ignoressafearea(_:edges:)"
---

# ignoresSafeArea(_:edges:)

Expands the safe area of a view.

## Declaration

```swift
nonisolated func ignoresSafeArea(_ regions: SafeAreaRegions = .all, edges: Edge.Set = .all) -> some View

```

## Parameters

- `regions`: The regions to expand the view’s safe area into. The modifier expands into all safe area region types by default.
- `edges`: The set of edges to expand. Any edges that you don’t include in this set remain unchanged. The set includes all edges by default.

## Mentioned in

Adding a background to your view

## Return Value

Return Value A view with an expanded safe area.

## Discussion

Discussion By default, the SwiftUI layout system sizes and positions views to avoid certain safe areas. This ensures that system content like the software keyboard or edges of the device don’t obstruct your views. To extend your content into these regions, you can ignore safe areas on specific edges by applying this modifier. When expanding the safe area, the SwiftUI layout system proposes the expanded size to the view. If your view has a fixed size, the alignment of the view may not be what you expect. By default, SwiftUI resolves the alignment based on the edges being ignored. For example, providing only the bottom edge will result in a bottom alignment being used. You can use the View/ignoresSafeArea(_:alignment:) modifier to explicitly configure the alignment. For examples of how to use this modifier, see Adding a background to your view.

## See Also

### Staying in the safe areas

- [ignoresSafeArea(_:edges:alignment:)](swiftui/view/ignoressafearea(_:edges:alignment:).md)
- [safeAreaInset(edge:alignment:spacing:content:)](swiftui/view/safeareainset(edge:alignment:spacing:content:).md)
- [safeAreaPadding(_:)](swiftui/view/safeareapadding(_:).md)
- [safeAreaPadding(_:_:)](swiftui/view/safeareapadding(_:_:).md)
- [SafeAreaRegions](swiftui/safearearegions.md)
