# React Native Gesture Handler — card for AI agents

Declarative gesture handling for React Native with native performance.

Category: Desktop and mobile apps · npm package `react-native-gesture-handler` · latest version 3.4.0 (checked 2026-11-01)
Install: `npm install react-native-gesture-handler`
License: MIT (permissive)

In your own product (generator, app, hosted service): **yes**. Permissive license: ship it inside your own product, closed or open source, and keep its license and copyright notice.

## Rules for AI agents (paste into AGENTS.md or CLAUDE.md)

## React Native Gesture Handler
- In Expo projects, install with `npx expo install react-native-gesture-handler`. For an Expo development build, run `npx expo prebuild` to update the native code.
- Wrap the app in `GestureHandlerRootView`, as close to the actual root as possible. Gestures outside it are not recognized.
- Wrap `Modal` content in its own `GestureHandlerRootView`. With wix/react-native-navigation, wrap every registered screen.
- In 3.x, create gestures with hooks such as `useTapGesture` and attach them with `GestureDetector`.
- For gestures on the same component, use `useCompetingGestures`, `useSimultaneousGestures` or `useExclusiveGestures`. Across components, use `simultaneousWith`, `requireToFail` or `block`.
- Do not try to set relations between hook-based gestures and gestures from previous APIs.
- For UI-thread gesture animation, the recommended route is `react-native-reanimated` plus `react-native-worklets`. Check that the React Native version is in the compatibility table, because 3.x needs at least 0.82.

## Docs written for agents
- [llms.txt (index of the docs)](https://docs.swmansion.com/react-native-gesture-handler/llms.txt)

## What it is
- React Native Gesture Handler is Software Mansion's MIT-licensed library for touch and gestures in React Native. The GitHub repository was created on 2016-10-27. The docs say it is "designed to be a replacement" for React Native's built-in Gesture Responder System.
- The JS responder system no longer controls gestures. The README says they are recognized and tracked on the UI thread. To use it, you wrap the app in `GestureHandlerRootView`, create a gesture with a hook such as `useTapGesture`, and attach it to a view with `GestureDetector`. The library also ships components, including swipeable rows, a drawer layout, buttons, Pressable and a new Touchable.
- The getting-started docs give setup steps for Android, iOS, macOS and the web, plus Expo development builds. The current docs cover version 3.x, which shows gestures created with hooks. The docs also refer to "previous APIs" that sit alongside the hook-based one.

## Caveats
- Three-minor React Native window: The docs say the library supports the three latest minor releases of React Native. The 3.x compatibility table covers React Native 0.82 to 0.87. It marks 3.3.x as not supporting 0.82.
- Version 3 needs React Native 0.82+: Projects on older React Native versions stay on Gesture Handler 2. The README links to the version 3 compatibility table in the docs and lists a separate table for version 2.
- Everything must sit under the root view: Gestures outside `GestureHandlerRootView` are not recognized. Relations only work between gestures under the same root. The docs say Modal content and, with wix/react-native-navigation, every screen need their own wrapper.
- Hook API and older APIs don't connect: You cannot set relations between gestures from the hook-based API and gestures from previous APIs. The docs mark this as a danger note.
- UI-thread animation means two more packages: The docs recommend Reanimated for gesture-driven interactions on the UI thread. That requires installing `react-native-reanimated` and `react-native-worklets`. React Native's Animated API is the other option the docs give.

## Numbers (AgentGid data)
- Gid Score: 67.8 (#494 of all tools, 11 of 105 in its category)
- Used in 99 public projects set up for AI coding agents (1.6%)
- Downloads last week: 14,675,866 (as of 2026-11-24), +53.5% over 4 weeks
- GitHub stars: 6,807 (as of 2026-11-24)
- Last push: 2026-11-19

## Often used with
React Native 100.0%, react-native-safe-area-context 100.0%, react-native-screens 99.0%, Expo 96.0%, React Native Reanimated 92.9%, React 100.0%

## Links
- AgentGid page: https://agentgid.com/tools/react-native-gesture-handler/
- Homepage: https://docs.swmansion.com/react-native-gesture-handler/
- Repository: https://github.com/software-mansion/react-native-gesture-handler
- Source: https://github.com/software-mansion/react-native-gesture-handler#readme
- Source: https://github.com/software-mansion/react-native-gesture-handler
- Source: https://github.com/software-mansion/react-native-gesture-handler/releases
- Source: https://docs.swmansion.com/react-native-gesture-handler/
- Source: https://docs.swmansion.com/react-native-gesture-handler/docs/composition/overview
- Source: https://docs.swmansion.com/react-native-gesture-handler/docs/fundamentals/getting-started

---
AgentGid's catalog is curated: every entry was checked against the maker's official pages (registry, repository, license and pricing pages) on the date shown; a license value shows the quote it stands on wherever AgentGid has one. Usage numbers come from AgentGid's own scan of public repositories set up for AI coding agents. Claims by makers are reported, not tested by AgentGid.
