A high-performance HTTP server for React Native, built on Rust's Actix-web framework and integrated via Nitro Modules for native async FFI calls. Version 1.9.2 supports iOS and Android, offering features like static file serving, WebSocket, file upload, URL rewriting, and directory listing. It provides TypeScript-friendly APIs with zero-copy Rust bindings, streaming request/response bodies, and a plugin system (WebDAV, Zip mount). Actively maintained on GitHub by iwater, with a release cadence of about monthly updates. Differentiators: Rust-based performance vs JS-based alternatives, direct FFI without bridge overhead, and compatibility with Node.js http module API.
npm install react-native-nitro-http-serverNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows creating an HttpServer, starting on a random port (0), handling a request with JSON response, and logging the actual port.
Call `await server.stop()` in app lifecycle hooks (e.g., AppState 'background' listener).
Run `cd ios && pod install` in your project root.
Use `const actualPort = await server.start(0, handler);` and use `actualPort` instead of assuming the input port.
Use a reverse proxy if HTTPS is needed.
Refer to plugin documentation in the repository for specific installation and configuration.
Run `npm install react-native-nitro-http-server` and ensure `react-native-nitro-modules` is also installed.
Use `import { HttpServer } from 'react-native-nitro-http-server'` (curly braces).Run `npm install` and `npx react-native start --reset-cache`.
For iOS: run `cd ios && pod install`. For Android: ensure `react-native-nitro-modules` is properly linked (autolinking should work).