Objective-C
Also called ObjC, Objective-C++
What is Objective-C in React Native?
Objective-C is Apple’s older iOS language; much of React Native’s iOS core and many libraries still use it, often as Objective-C++ to reach C++ code like JSI.
Objective-C is the language Apple platforms were built on before Swift arrived. It adds Smalltalk-style messaging to C, and React Native’s iOS code — the RCT classes, the app host and a large share of community libraries — is written in it.
Its variant, Objective-C++, is why it remains relevant. A file with the .mm extension can mix Objective-C and C++ freely, and React Native’s New Architecture is C++ at its core: JSI, the Fabric renderer and TurboModules all expose C++ interfaces. Objective-C++ is the glue that lets iOS code plug into them, which is why generated TurboModule and Fabric component code on iOS is .mm, not Swift.
What you will recognise in React Native code:
.hheader and.mor.mmimplementation files.- Macros such as
RCT_EXPORT_MODULE()andRCT_EXPORT_METHOD(), from the classic native module system. - Square-bracket method calls like
[UIApplication sharedApplication].
#import <React/RCTBridgeModule.h>
@interface RCT_EXTERN_MODULE(Haptics, NSObject)
RCT_EXTERN_METHOD(tap)
@end
That pattern is the thin Objective-C file that exposes a Swift class to React Native.
The common gotcha is file extensions. Renaming an .m file to .mm changes the compiler used, so a module that suddenly needs to include a C++ header must become Objective-C++; forgetting this produces baffling errors about unknown C++ syntax. The reverse also matters: Swift cannot import C++ headers the same way, so you cannot simply rewrite every .mm file in Swift.
You do not need to master Objective-C to work with React Native, but being able to read it makes library source code and native stack traces far less intimidating.