I’m developing a React Native application that needs to connect to devices over HTTPS. These devices provide only self-signed SSL certificates.
In browsers (e.g., Firefox), users can bypass the warning and continue. In React Native, however, all standard approaches seem to block the connection and fail with certificate errors.
What I’ve tried
- Using react-native-ssl-pinning with disableAllSecurity: true.
- Writing a custom native iOS module with URLSessionDelegate that trusts all certificates.
- Trying to load the content via WebView with mixedContentMode="always" and allowing all requests
Question
Is there a properly supported way in React Native to handle or accept self-signed SSL certificates in production builds (not debug)?
The solution must also remain compatible with App Store and Google Play review requirements.
Any guidance or best practices would be appreciated.