Skip to content

Sticky headers in FlatList/ScrollView become non-touchable after upgrading to 0.79.2 #51763

Open

Description

@ajayrajtiwari

Description

After upgrading to React Native version 0.79.2, sticky header indices (stickyHeaderIndices) in both FlatList and ScrollView components become non-responsive to touch events. The content renders correctly but fails to respond to any user interaction (taps, presses, etc.).

Expected Behavior:
Sticky headers should remain touchable/interactive as in previous versions (e.g., 0.79.1 or earlier), allowing users to interact with buttons, links, or other touchable elements within them.

Observed Behavior:
Sticky headers are visually rendered but ignore all touch events. This breaks functionality for interactive elements (e.g., buttons, checkboxes) within sticky sections.

Reproduction Steps:
Create a FlatList or ScrollView with stickyHeaderIndices set.
Add touchable elements (e.g., TouchableOpacity, Button) inside the sticky header.
Upgrade to RN 0.79.2.
Observe that touch events on sticky headers no longer work.

<ScrollView
style={{ flex: 1 }}
ref={scrollViewRef}
stickyHeaderIndices={[1]}
onScroll={handleScroll}
scrollEventThrottle={16}
nestedScrollEnabled>
.....

Environment:
React Native: 0.79.2
Platform: Android (observed)
Device: All Real devices

Steps to reproduce

Create a FlatList or ScrollView with stickyHeaderIndices set.
Add touchable elements (e.g., TouchableOpacity, Button) inside the sticky header.
Upgrade to RN 0.79.2.
Observe that touch events on sticky headers no longer work.

non_touches.mp4

React Native Version

0.79.2

Affected Platforms

Runtime - Android

Output of npx @react-native-community/cli info

System:
  OS: macOS 15.3.1
  CPU: (8) arm64 Apple M2
  Memory: 171.11 MB / 8.00 GB
  Shell:
    version: "5.9"
    path: /bin/zsh
Binaries:
  Node:
    version: 22.14.0
    path: ~/.nvm/versions/node/v22.14.0/bin/node
  Yarn:
    version: 3.6.4
    path: ~/.yarn/bin/yarn
  npm:
    version: 10.9.2
    path: ~/.nvm/versions/node/v22.14.0/bin/npm
  Watchman:
    version: 2025.04.28.00
    path: /opt/homebrew/bin/watchman
Managers:
  CocoaPods:
    version: 1.16.2
    path: /Users/mac/.gem/ruby/3.4.0/bin/pod
SDKs:
  iOS SDK:
    Platforms:
      - DriverKit 24.4
      - iOS 18.4
      - macOS 15.4
      - tvOS 18.4
      - visionOS 2.4
      - watchOS 11.4
  Android SDK:
    API Levels:
      - "33"
      - "34"
      - "35"
    Build Tools:
      - 33.0.1
      - 34.0.0
      - 35.0.0
      - 35.0.1
    System Images:
      - android-29 | Google APIs ARM 64 v8a
      - android-35 | Google APIs ARM 64 v8a
      - android-35 | Google Play ARM 64 v8a
    Android NDK: Not Found
IDEs:
  Android Studio: 2024.2 AI-242.23726.103.2422.13016713
  Xcode:
    version: 16.3/16E140
    path: /usr/bin/xcodebuild
Languages:
  Java:
    version: 17.0.14
    path: /usr/bin/javac
  Ruby:
    version: 3.4.2
    path: /opt/homebrew/opt/ruby/bin/ruby
npmPackages:
  "@react-native-community/cli":
    installed: 18.0.0
    wanted: 18.0.0
  react:
    installed: 19.0.0
    wanted: 19.0.0
  react-native:
    installed: 0.79.2
    wanted: 0.79.2
  react-native-macos: Not Found
npmGlobalPackages:
  "*react-native*": Not Found
Android:
  hermesEnabled: true
  newArchEnabled: true
iOS:
  hermesEnabled: true
  newArchEnabled: true

Stacktrace or Logs

System:
  OS: macOS 15.3.1
  CPU: (8) arm64 Apple M2
  Memory: 171.11 MB / 8.00 GB
  Shell:
    version: "5.9"
    path: /bin/zsh
Binaries:
  Node:
    version: 22.14.0
    path: ~/.nvm/versions/node/v22.14.0/bin/node
  Yarn:
    version: 3.6.4
    path: ~/.yarn/bin/yarn
  npm:
    version: 10.9.2
    path: ~/.nvm/versions/node/v22.14.0/bin/npm
  Watchman:
    version: 2025.04.28.00
    path: /opt/homebrew/bin/watchman
Managers:
  CocoaPods:
    version: 1.16.2
    path: /Users/mac/.gem/ruby/3.4.0/bin/pod
SDKs:
  iOS SDK:
    Platforms:
      - DriverKit 24.4
      - iOS 18.4
      - macOS 15.4
      - tvOS 18.4
      - visionOS 2.4
      - watchOS 11.4
  Android SDK:
    API Levels:
      - "33"
      - "34"
      - "35"
    Build Tools:
      - 33.0.1
      - 34.0.0
      - 35.0.0
      - 35.0.1
    System Images:
      - android-29 | Google APIs ARM 64 v8a
      - android-35 | Google APIs ARM 64 v8a
      - android-35 | Google Play ARM 64 v8a
    Android NDK: Not Found
IDEs:
  Android Studio: 2024.2 AI-242.23726.103.2422.13016713
  Xcode:
    version: 16.3/16E140
    path: /usr/bin/xcodebuild
Languages:
  Java:
    version: 17.0.14
    path: /usr/bin/javac
  Ruby:
    version: 3.4.2
    path: /opt/homebrew/opt/ruby/bin/ruby
npmPackages:
  "@react-native-community/cli":
    installed: 18.0.0
    wanted: 18.0.0
  react:
    installed: 19.0.0
    wanted: 19.0.0
  react-native:
    installed: 0.79.2
    wanted: 0.79.2
  react-native-macos: Not Found
npmGlobalPackages:
  "*react-native*": Not Found
Android:
  hermesEnabled: true
  newArchEnabled: true
iOS:
  hermesEnabled: true
  newArchEnabled: true

MANDATORY Reproducer

https://github.com/ajprince21/rn-bug-1/blob/main/index.js

Screenshots and Videos

No response

Activity

  1. mateoguzmana commented on Jun 3, 2025

    @mateoguzmana
    Collaborator

    Seems to be working well for me in both legacy and new architecture. Not sure if it is something that got fixed in between, but is there any other behaviour you expect other than the console.logs?

    Image

    Image

  2. liao666brant commented on Jun 6, 2025

    @liao666brant

    I have the same problem, is there a temporary solution?

  3. Mootzali commented on Jun 7, 2025

    @Mootzali

    I have the same problem, mentioned it in : #51290

  4. julian-dueck commented on Jun 20, 2025

    @julian-dueck

    same issue for me in react-native: 0.79.3

    a workaround i found is replacing onPress with either onPressIn or onPressOut

  5. liao666brant commented on Jun 26, 2025

    @liao666brant

    same issue for me in react-native: 0.79.3

    a workaround i found is replacing onPress with either onPressIn 或 onPressOut

    This method is very effective

  6. ajayrajtiwari commented on Jun 27, 2025

    @ajayrajtiwari
    Author

    same issue for me in react-native: 0.79.3

    a workaround i found is replacing onPress with either onPressIn or onPressOut

    Thanks buddy works for me too 👌🏻 But Required a permanent solution from team RN

  7. julian-dueck commented on Jun 27, 2025

    @julian-dueck

    Seems to be working well for me in both legacy and new architecture. Not sure if it is something that got fixed in between, but is there any other behaviour you expect other than the console.logs?

    Image

    Image

    hello @mateoguzmana , quick question. Did you scroll down and then try to tap? this only happens when the header becomes pinned at the top. when you scroll back up and the header becomes unpinned, it works again. I also noticed this behaviour in SectionList

  8. oserrabassa-jcm commented on Jul 17, 2025

    @oserrabassa-jcm

    Same issue

  9. Sameed1998 commented on Jul 18, 2025

    @Sameed1998

    Having same issue i fixed it by using Pressable from react-native-gesture-handler

  10. 18 remaining items

  11. cd-butterfly commented on Mar 17, 2026

    @cd-butterfly

    I have refactored my entire project using react-native-gesture-handler's Pressable to address the sticky header interaction issue. This massive refactor was necessary because our sticky headers consist of multiple nested sub-components. Since it's impossible to predict which sub-components will be used within a sticky context, we had to replace all legacy Touchables across the codebase to ensure no interactive elements are missed. I hope the official team can provide a fundamental fix for this behavior.

  12. TeamAntani commented on Mar 25, 2026

    @TeamAntani

    still broken is 0.84.1

  13. uloco commented on Apr 30, 2026

    @uloco
    Contributor

    @gauravkumar1007 Your fix does not work at all. I think it is AI generated and misleading.

  14. aditya-thummar-devx commented on Apr 30, 2026

    @aditya-thummar-devx

    @uloco I was facing same issue, and hopefully got workaround.
    Use Pressable from react-native-gesture-handler. Works like a charm !!

    import { Pressable } from 'react-native-gesture-handler';
    
     <Pressable onPress={handlePress} >
        ...
     </Pressable>
    
  15. aditya-thummar-devx commented on Apr 30, 2026

    @aditya-thummar-devx

    @uloco Let me know if this works, react if you can. So others can get an idea that is it only working for my project or it's actually temporary workaround.

  16. uloco commented on Apr 30, 2026

    @uloco
    Contributor

    Yes using the Pressable from react-native-gesture-handler works but has different issues in my specific project. I was looking for a better workaround but this is fine for now.

  17. aditya-thummar-devx commented on Apr 30, 2026

    @aditya-thummar-devx

    Yes using the Pressable from react-native-gesture-handler works but has different issues in my specific project. I was looking for a better workaround but this is fine for now.

    Yeah, Maybe it won't provide the style effect same as TouchableOpacity. But you can use the conditional or animated styles if needed.

  18. aditya-thummar-devx commented on Apr 30, 2026

    @aditya-thummar-devx

    Yes using the Pressable from react-native-gesture-handler works but has different issues in my specific project. I was looking for a better workaround but this is fine for now.

    Let me know if I can help with your other issue related to using Pressable

  19. christophby commented on Jul 1, 2026

    @christophby

    Does it work again?

  20. uloco commented on Jul 1, 2026

    @uloco
    Contributor

    @christophby why would it? like did you release a new version that should fix this? could you please link or specify any details?

  21. Brma1048 commented on Jul 16, 2026

    @Brma1048

    still having this issue

  22. Mootzali commented on Jul 18, 2026

    @Mootzali

    @Brma1048 You can use Pressable or Touchable components from react-native-gesture-handler as a workaround. It doesn't fix the underlying issue, but it works.

  23. Brma1048 commented on Jul 23, 2026

    @Brma1048

    @Mootzali Yes i know but the problem with this is if i mix the Pressable from react-native-gesture-handler and react-native it triggers both onPress. So for example when i have a parent view with react-native Pressable and a child with react-native-gesture-handler Pressable it triggers both onPress.

  24. jakub-oone commented on Jul 29, 2026

    @jakub-oone

    I have fix that touchability issue in sticked header on Android. Here is a patch file. Also working with RN 0.86, just rename the file...

    react-native+0.84.1.patch

  25. rehan15701 commented on Sep 24, 2026

    @rehan15701

    same issue for me in react-native: 0.79.3

    a workaround i found is replacing onPress with either onPressIn or onPressOut

    Julian 's workaround worked for me , Even my project is running on "react-native": "0.79.3"

    "a workaround i found is replacing onPress with either onPressIn or onPressOut"

    I have used onPressOut

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions