---
title: "Concentric Rectangle | Explore SwiftUI"
description: "A concentric rectangle whose corner radii are defined from the same circle center as its parent element. The outermost parent is the device frame"
canonical_url: "https://exploreswiftui.com/library/concentricrectangle/concentric-rectangle"
meta:
  author: "Explore SwiftUI"
  "og:description": "A concentric rectangle whose corner radii are defined from the same circle center as its parent element. The outermost parent is the device frame"
  "og:image": "https://exploreswiftui.com/_og/d/c_Component%2Ctitle_Concentric%2BRectangle%2Cdescription_A%2Bconcentric%2Brectangle%2Bwhose%2Bcorner%2Bradii%2Bare%2Bdefined%2Bfrom%2Bthe%2Bsame%2Bcircle%2Bcenter%2Bas%2Bits%2Bparent%2Belement.%2BThe%2Boutermost%2Bparent%2Bis%2Bthe%2Bdevice%2Bframe.%2Ccategory_ConcentricRectangle%2Cimage_~L2FwaS9pbWFnZXMvMTUzL3ZhcmlhbnRzLzQ5OD92PTE3OTUwODU3Mjk1NDImcj0yJnc9MTI4MCZxPTg1JmY9anBlZw%2CimageMode_crop%2CimagePosition_bottom%2CimageFrame_~cG9zaXRpb246IGFic29sdXRlOyByaWdodDogMDsgd2lkdGg6IDY0MHB4OyBoZWlnaHQ6IDQ4MHB4OyBkaXNwbGF5OiBmbGV4OyBvdmVyZmxvdzogaGlkZGVuOyBiYWNrZ3JvdW5kOiAjRkZGRkZGOyBib3gtc2hhZG93OiAwIC0xMHB4IDUwcHggcmdiYSgzNyw5OSwyMzUsMC4xOCk7IGJvcmRlci1sZWZ0OiAxcHggc29saWQgcmdiYSgwLDAsMCwwLjA2KTsgdG9wOiAwOyBib3JkZXItYm90dG9tOiAxcHggc29saWQgcmdiYSgwLDAsMCwwLjA2KTsgYm9yZGVyLWJvdHRvbS1sZWZ0LXJhZGl1czogNzRweDs%2Cprops_eyJwbGF0Zm9ybXMiOlsiaU9TIiwiaVBhZE9TIiwibWFjT1MiLCJ3YXRjaE9TIiwidHZPUyIsInZpc2lvbk9TIl19%2Cp_Ii9saWJyYXJ5L2NvbmNlbnRyaWNyZWN0YW5nbGUvY29uY2VudHJpYy1yZWN0YW5nbGUi%2Cs_l44H9y2HH4z22fA-.png"
  "og:image:height": "630"
  "og:image:type": image/png
  "og:image:width": "1200"
  "og:title": "Concentric Rectangle | Explore SwiftUI"
  "twitter:description": "A concentric rectangle whose corner radii are defined from the same circle center as its parent element. The outermost parent is the device frame"
  "twitter:image": "https://exploreswiftui.com/_og/d/c_Component%2Ctitle_Concentric%2BRectangle%2Cdescription_A%2Bconcentric%2Brectangle%2Bwhose%2Bcorner%2Bradii%2Bare%2Bdefined%2Bfrom%2Bthe%2Bsame%2Bcircle%2Bcenter%2Bas%2Bits%2Bparent%2Belement.%2BThe%2Boutermost%2Bparent%2Bis%2Bthe%2Bdevice%2Bframe.%2Ccategory_ConcentricRectangle%2Cimage_~L2FwaS9pbWFnZXMvMTUzL3ZhcmlhbnRzLzQ5OD92PTE3OTUwODU3Mjk1NDImcj0yJnc9MTI4MCZxPTg1JmY9anBlZw%2CimageMode_crop%2CimagePosition_bottom%2CimageFrame_~cG9zaXRpb246IGFic29sdXRlOyByaWdodDogMDsgd2lkdGg6IDY0MHB4OyBoZWlnaHQ6IDQ4MHB4OyBkaXNwbGF5OiBmbGV4OyBvdmVyZmxvdzogaGlkZGVuOyBiYWNrZ3JvdW5kOiAjRkZGRkZGOyBib3gtc2hhZG93OiAwIC0xMHB4IDUwcHggcmdiYSgzNyw5OSwyMzUsMC4xOCk7IGJvcmRlci1sZWZ0OiAxcHggc29saWQgcmdiYSgwLDAsMCwwLjA2KTsgdG9wOiAwOyBib3JkZXItYm90dG9tOiAxcHggc29saWQgcmdiYSgwLDAsMCwwLjA2KTsgYm9yZGVyLWJvdHRvbS1sZWZ0LXJhZGl1czogNzRweDs%2Cprops_eyJwbGF0Zm9ybXMiOlsiaU9TIiwiaVBhZE9TIiwibWFjT1MiLCJ3YXRjaE9TIiwidHZPUyIsInZpc2lvbk9TIl19%2Cp_Ii9saWJyYXJ5L2NvbmNlbnRyaWNyZWN0YW5nbGUvY29uY2VudHJpYy1yZWN0YW5nbGUi%2Cs_l44H9y2HH4z22fA-.png"
  "twitter:title": "Concentric Rectangle | Explore SwiftUI"
---

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

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

# **Concentric Rectangle**

A concentric rectangle whose corner radii are defined from the same circle center as its parent element. The outermost parent is the device frame.

![Concentric Rectangle - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/153/variants/498?v=1795085729542&r=2&w=800&q=80&f=webp)

### **Platform Compatibility**

iOS 26.0+ iPadOS 26.0+ macOS 26.0+ watchOS 26.0+ tvOS 26.0+ visionOS 26.0+

### **Tags**

### **SwiftUI Code**

[ Docs](<https://developer.apple.com/documentation/swiftui/concentricrectangle/init()>)

```
ZStack(alignment: .bottom) {
    // Respects radius from devide frame
    ConcentricRectangle()
        .fill(Color.blue)
        .frame(height: 50)
        .frame(maxHeight: .infinity, alignment: .bottom)
        .padding(30)
        .ignoresSafeArea()

    ZStack {
        // Gets radius from parent rect
        ConcentricRectangle()
            .fill(.secondary)

        // Respects radius from parent rect
        ConcentricRectangle()
            .fill(.red)
            .frame(width: 200, height: 200)
            .padding([.trailing, .bottom])
    }
    .containerShape(
            .rect(cornerRadius: 42)
    )
    .frame(width: 250, height: 250)
    .padding(.bottom)
}
```

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

Created: February 28, 2026Updated: November 19, 2026

### **More ConcentricRectangle Components **

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

![Uniform Concentric Rectangle - iOS on iPhone - Portrait - Liquid Glass - Light Mode - Preview](https://exploreswiftui.com/api/images/154/variants/500?v=1795085724134&r=2&w=412&q=75&f=webp)

### **Uniform Concentric Rectangle**

Create a rectangle with the same corner style set on four corners.

### **Explore Other Components **

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

![FieldDatePickerStyle - macOS - Flat Design - Light Mode - Preview](https://exploreswiftui.com/api/images/65/variants/324?v=1790073478842&r=2&w=412&q=75&f=webp)

### **FieldDatePickerStyle**

A date picker style that displays the components in an editable field

![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

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

### **Divider Height**

Customizing the height of the Divider

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

### **Menu Fixed Order**

Order items from top to bottom

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

### **DatePicker Colors**

Customizing the colors of the date picker

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

### **Button Roles**

A value that describes the purpose of a button.

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

### **Outline Group**

A structure that computes views and disclosure groups on demand from an underlying collection of tree-structured, identified data.

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

### **Button Sizing**

The preferred sizing behavior of buttons in the view hierarchy.

```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/concentricrectangle/concentric-rectangle#webpage","@type":"WebPage","dateModified":"2026-11-19T10:55:29.552Z","datePublished":"2026-02-28T14:46:51.906Z","description":"A concentric rectangle whose corner radii are defined from the same circle center as its parent element. The outermost parent is the device frame","name":"Concentric Rectangle","url":"https://exploreswiftui.com/library/concentricrectangle/concentric-rectangle","breadcrumb":{"@id":"https://exploreswiftui.com/library/concentricrectangle/concentric-rectangle#breadcrumb"},"isPartOf":{"@id":"https://exploreswiftui.com/#website"},"mainEntity":{"@id":"https://exploreswiftui.com/library/concentricrectangle/concentric-rectangle#article"},"potentialAction":[{"@type":"ReadAction","target":["https://exploreswiftui.com/library/concentricrectangle/concentric-rectangle"]}],"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/concentricrectangle/concentric-rectangle#article","citation":"https://developer.apple.com/documentation/swiftui/concentricrectangle/init()","dateModified":"2026-11-19T10:55:29.552Z","datePublished":"2026-02-28T14:46:51.906Z","description":"A concentric rectangle whose corner radii are defined from the same circle center as its parent element. The outermost parent is the device frame","headline":"Concentric Rectangle","inLanguage":"en-US","name":"Concentric Rectangle","thumbnailUrl":"https://exploreswiftui.com/api/images/153/variants/498?v=1795085729542&r=2","url":"https://exploreswiftui.com/library/concentricrectangle/concentric-rectangle","@type":["Article","TechArticle"],"about":{"@type":"Thing","name":"SwiftUI"},"author":{"@id":"https://exploreswiftui.com/#identity"},"hasPart":{"@id":"https://exploreswiftui.com/library/concentricrectangle/concentric-rectangle#source-code"},"image":{"@id":"https://exploreswiftui.com/#/schema/image/1"},"isPartOf":{"@id":"https://exploreswiftui.com/library/concentricrectangle/concentric-rectangle#webpage"},"mainEntityOfPage":{"@id":"https://exploreswiftui.com/library/concentricrectangle/concentric-rectangle#webpage"},"publisher":{"@id":"https://exploreswiftui.com/#identity"}},{"@id":"https://exploreswiftui.com/library/concentricrectangle/concentric-rectangle#source-code","@type":"SoftwareSourceCode","codeSampleType":"full example","description":"A concentric rectangle whose corner radii are defined from the same circle center as its parent element. The outermost parent is the device frame","name":"Concentric Rectangle SwiftUI Example","programmingLanguage":"Swift","runtimePlatform":"SwiftUI","text":"ZStack(alignment: .bottom) {\n    // Respects radius from devide frame\n    ConcentricRectangle()\n        .fill(Color.blue)\n        .frame(height: 50)\n        .frame(maxHeight: .infinity, alignment: .bottom)\n        .padding(30)\n        .ignoresSafeArea()\n\n    ZStack {\n        // Gets radius from parent rect\n        ConcentricRectangle()\n            .fill(.secondary)\n\n        // Respects radius from parent rect\n        ConcentricRectangle()\n            .fill(.red)\n            .frame(width: 200, height: 200)\n            .padding([.trailing, .bottom])\n    }\n    .containerShape(\n            .rect(cornerRadius: 42)\n    )\n    .frame(width: 250, height: 250)\n    .padding(.bottom)\n}","about":[{"@type":"Thing","name":"SwiftUI"},{"@type":"Thing","name":"ConcentricRectangle"},{"@type":"Thing","name":"Concentric Rectangle"}]},{"@id":"https://exploreswiftui.com/library/concentricrectangle/concentric-rectangle#breadcrumb","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","name":"Home","item":"https://exploreswiftui.com","position":1},{"@type":"ListItem","name":"ConcentricRectangle","item":"https://exploreswiftui.com/library/concentricrectangle","position":2},{"@type":"ListItem","name":"Concentric Rectangle","item":"https://exploreswiftui.com/library/concentricrectangle/concentric-rectangle","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/153/variants/498?v=1795085729542&r=2","inLanguage":"en","url":"https://exploreswiftui.com/api/images/153/variants/498?v=1795085729542&r=2"}]}
```