Appearance module exposes information about the user’s appearance preferences, such as their preferred color scheme (light or dark).
Developer notes
Example
You can use theAppearance module to determine if the user prefers a dark color scheme:
useColorScheme React hook as it provides and subscribes to color scheme updates, or you may use inline styles rather than setting a value in a StyleSheet.
Reference
Methods
getColorScheme()
setColorScheme) or on a schedule (e.g. light and dark themes that follow the day/night cycle).
Supported color schemes:
'light': The user prefers a light color theme.'dark': The user prefers a dark color theme.null: The user has not indicated a preferred color theme.
useColorScheme hook.
setColorScheme()
null which causes the application to inherit the system’s interface style. If you assign a different value, the new style applies to the application and all native elements within the application (Alerts, Pickers etc).
Supported color schemes:
light: Apply light user interface style.dark: Apply dark user interface style.- null: Follow the system’s interface style.

