dnd-kit
freeAccessible drag-and-drop toolkit for React: sortable lists, kanban boards, keyboard dragging.

Try these
Pragmatic drag and drop
Atlassian's tiny, framework-agnostic drag-and-drop built on the native HTML5 DnD API (powers Trello and Jira).
FormKit Drag and Drop
Data-first sortable lists in about 4 KB: your array is the source of truth and reorders as you drag.
Motion
The default animation library for React (formerly Framer Motion): springs, gestures, layout and exit animations.
shadcn/ui
Copy-in React components on Tailwind, built on Base UI, Radix or React Aria, plus a registry CLI.
Looks that pick it
For your agent
Install
npm i @dnd-kit/react @dnd-kit/helpersUse it for
- drag to reorder list items or cards with keyboard and screen-reader support
- a sortable list or settings order that must work with the keyboard
- a kanban board with cards moving between columns
- reorderable dashboard widgets or a sortable grid
Skip it when
- dragging a divider to resize split panes or panels: the kit's Resizable part (react-resizable-panels under shadcn/ui)
- very large boards or virtualised lists in an enterprise app: pragmatic-drag-and-drop is lighter and built for scale
- a quick sortable list where data-first simplicity matters more than a11y: formkit-drag-and-drop is less code
- file upload drop zones: use the native drop event or react-dropzone
What's inside22 free
- DragDropProvider
- DragOverlay
- useDraggable
- useDroppable
- useSortable
- useDragDropManager
- useDragDropMonitor
- useDragOperation
- PointerSensor
- KeyboardSensor
- Accessibility
- AutoScroller
- Cursor
- Feedback
- Debug
- RestrictToHorizontalAxis
- RestrictToVerticalAxis
- RestrictToWindow
- RestrictToElement
- SnapModifier
- Collision detection
- Multiple sortable lists
Facts
- Frameworks
- react, vue, svelte, solid, vanilla
- Styling
- unstyled
- Weight
- small
- Accessibility
- strong
- Maturity
- stable
- License
- MIT
- Price
- Free
Alternatives
import { DragDropProvider } from '@dnd-kit/react'
import { useSortable } from '@dnd-kit/react/sortable'
import { move } from '@dnd-kit/helpers'
function Item({ id, index }: { id: string; index: number }) {
const { ref } = useSortable({ id, index })
return <li ref={ref}>{id}</li>
}
const [items, setItems] = useState(['a', 'b', 'c'])
<DragDropProvider onDragEnd={(event) => setItems((items) => move(items, event))}>
<ul>{items.map((id, index) => <Item key={id} id={id} index={index} />)}</ul>
</DragDropProvider>https://dndkit.com
Loading website