> For the complete documentation index, see [llms.txt](https://airbnb.gitbook.io/lottie/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://airbnb.gitbook.io/lottie/android/caching-and-preloading.md).

# Caching and Preloading

If your animation will be frequently reused, `LottieAnimationView` has an optional caching strategy built in. Use `LottieAnimationView#setAnimation(String, CacheStrategy)`. `CacheStrategy` can be `Strong`, `Weak`, or `None` to have `LottieAnimationView` hold a strong or weak reference to the loaded and parsed animation.

You can also load a LottieComposition manually, hold a reference to it, and call `LottieAnimationView#setComposition(LottieComposition)` with the composition to have the animation load instantly rather than waiting for the deserialization.
