Multiple Suspense Boundaries: Nested vs Sibling
What you'll learn: How to use multiple Suspense boundaries strategically—nested for progressive loading experiences or side-by-side for independent parallel sections.
The Two Patterns
When you have multiple async operations in your app, you can organize Suspense boundaries in two distinct ways:
Sibling boundaries sit next to each other at the same level, letting independent sections load in parallel without blocking each other. Think of multiple browser tabs loading simultaneously—one slow tab doesn't freeze the others.
Nested boundaries stack inside each other, creating a progressive loading experience where outer content appears first, then inner content fills in. Imagine opening a news site: the header loads, then the article list, then comment counts within each article.
When to Use Each
Use sibling boundaries when you have independent features on the same page:
<div>
<Suspense fallback={<Spinner />}>
<UserProfile /> {/* loads independently */}
</Suspense>
<Suspense fallback={<Spinner />}>
<RecommendedPosts /> {/* loads independently */}
</Suspense>
</div>
Both sections show their own spinners and resolve independently. Fast data doesn't wait for slow data.
Use nested boundaries for hierarchical, progressive disclosure:
<Suspense fallback={<PageSkeleton />}>
<PageLayout>
<Suspense fallback={<CommentsSpinner />}>
<Comments /> {/* loads after layout */}
</Suspense>
</PageLayout>
</Suspense>
The outer boundary shows a skeleton for the whole page. Once that resolves, the page renders but shows a smaller spinner where comments will appear.
The Decision Point
Sibling = parallel independence. Nested = layered refinement.
Key Takeaway: Use sibling Suspense boundaries to load unrelated sections in parallel without blocking each other; use nested boundaries to progressively reveal content from coarse to detailed as data arrives hierarchically.