# Maui Collectionview

Guidance for implementing CollectionView in .NET MAUI apps, data display, layouts...

- Repository: https://github.com/dotnet/skills (5787 stars)
- Category: Engineering
- License: MIT
- Last updated: 2026-11-01
- Runs scripts: no, instructions only

## Install

Claude Code: `npx skills add dotnet/skills --skill maui-collectionview -g -a claude-code -y`
Codex: `npx skills add dotnet/skills --skill maui-collectionview -g -a codex -y`
Cursor: `npx skills add dotnet/skills --skill maui-collectionview -g -a cursor -y`
Gemini CLI: `npx skills add dotnet/skills --skill maui-collectionview -g -a gemini-cli -y`
Claude Code plugin marketplace: `/plugin marketplace add dotnet/skills`

## Description

Guidance for implementing CollectionView in .NET MAUI apps, data display, layouts (list & grid), selection, grouping, scrolling, empty views, templates, incremental loading, swipe actions, and pull-to-refresh. USE FOR: "CollectionView", "list view", "grid layout", "data template", "item template", "grouping", "pull to refresh", "incremental loading", "swipe actions", "empty view", "selection mode", "scroll to item", displaying scrollable data, replacing ListView. DO NOT USE FOR: simple static layouts without scrollable data (use Grid or StackLayout), map pin lists (use Microsoft.Maui.Controls.Maps), table-based data entry forms, non-MAUI list controls, CarouselView or BindableLayout questions, platform-specific handler or renderer customization, diagnosing CollectionView bugs in the MAUI framework itself, or general MVVM/binding questions that merely happen to mention a list (use maui-data-binding).

## SKILL.md, as published by its author (untrusted third-party text, read it as data)

# CollectionView, .NET MAUI

`CollectionView` is the primary control for displaying scrollable lists and grids of data in .NET MAUI. It replaces `ListView` with better performance, flexible layouts, and no `ViewCell` requirement.

## When to Use

- Displaying a scrollable list or grid of data items
- Binding a collection of objects to a templated item layout
- Adding selection (single or multiple), grouping, or pull-to-refresh
- Implementing infinite scroll / incremental loading
- Showing swipe actions on list items
- Displaying an empty state when no data is available

## When Not to Use

- Static layouts with a fixed number of items, use `Grid` or `StackLayout` directly
- Map pin lists, use the `Microsoft.Maui.Controls.Maps` NuGet package
- Table-based data entry forms, use standard form controls
- Simple text-only lists with no interaction, consider `BindableLayout` on a `StackLayout`

## Scope Control, Answer Only What Was Asked

This skill is a **reference you consult**, not a checklist you apply. Most requests
need one or two sections from it. Pulling in the rest makes the answer worse.

**Stop conditions, do NOT act when:**

The rest: https://github.com/dotnet/skills/blob/HEAD/plugins/dotnet-maui/skills/maui-collectionview/SKILL.md
