Skip to main content
This component is Android-only. It will not work on iOS or other platforms.ProgressBarAndroid has been extracted from react-native core and will be removed in a future release. It can now be installed and imported from @react-native-community/progress-bar-android instead of react-native.
React component that wraps the Android-only ProgressBar. This component is used to indicate that the app is loading or there is activity in the app.

Example

Props

styleAttr

Type: 'Horizontal' | 'Normal' | 'Small' | 'Large' | 'Inverse' | 'SmallInverse' | 'LargeInverse' Default: 'Normal' Style of the ProgressBar:
  • Horizontal - A horizontal progress bar
  • Normal - Circular, normal size (default)
  • Small - Circular, small size
  • Large - Circular, large size
  • Inverse - Circular, normal size, for use on dark backgrounds
  • SmallInverse - Circular, small size, for use on dark backgrounds
  • LargeInverse - Circular, large size, for use on dark backgrounds

indeterminate

Type: boolean Default: true If the progress bar will show indeterminate progress. Note that this can only be false if styleAttr is Horizontal.

progress

Type: number The progress value (between 0 and 1). This prop is only used when indeterminate is false.

animating

Type: boolean Default: true Whether to show the ProgressBar (true, the default) or hide it (false).

color

Type: ColorValue Color of the progress bar.

testID

Type: string Used to locate this view in end-to-end tests.

Complete Example