Fantasy sports apps live and die in a few busy minutes before a match starts. Users pick eleven players, choose a captain, join a contest and lock their team, often while the toss result is still sinking in. Small animations do a lot of work in that window. A tick that pops when a team is saved, a counter that rolls up when points land, a friendly loader while live scores refresh: these moments tell users the app heard them. Lottie has become one of the most common ways to build them, but it isn't the right tool for every animated element in a sports or gaming product.
This article looks at what Lottie actually is, where it fits well in fantasy cricket, football and other mobile game apps, how to keep it light, and when a video, a Rive file or a plain sprite sheet is the better call.
Lottie is an open-source animation format and set of players that started at Airbnb. A motion designer builds the animation in Adobe After Effects, then exports it with the Bodymovin plugin to a JSON file. The lottie-web repository on GitHub documents that exporter along with the web player, and native players read the same JSON on Android and iOS. Because the animation is stored as vector shapes and keyframes rather than pixels, it scales cleanly across screen sizes and usually weighs far less than an equivalent video.
There is a second format worth knowing: dotLottie, with the .lottie extension, promoted by LottieFiles. A dotLottie file is a ZIP archive that can bundle one or more animations together with their image assets, themes and state machines. For apps that ship several related animations, such as a set of badges or celebration effects, it keeps everything in one compressed file.
The practical upshot for a product team: designers keep working in tools they already know, and developers get a small file they can play, pause, loop or scrub from code.
The best uses are short, purposeful moments tied to user actions or app states. Here are the ones we see most often in fantasy and casual game apps.
First-time users need to understand the basics: pick players within a credit budget, choose a captain and vice-captain, join a contest. A three-screen onboarding flow with simple looping illustrations explains this faster than text. Lottie suits it because the files are small, they look sharp on any device, and you can tie playback to swipe progress.
The moment a user saves a team or pays an entry fee is the moment they most want reassurance. A one-second check mark, a shield closing or a ticket stamping gives that feedback without slowing the flow. Keep these under about a second and never block the next step while they play.
When a batter hits a boundary or a striker scores, fantasy points jump. A short burst or glow around the points total helps users notice the change. Pair a Lottie accent with a native text counter rather than animating the numbers themselves inside the file, so the values always come from your live data.
"No contests joined yet" or "No live matches right now" screens are a good place for a calm, branded loop. They also give your app some personality between match days.
Score refreshes, wallet updates and leaderboard loads all need a waiting indicator. A small branded loader is fine here, though a native progress indicator is often enough for very short waits.
These are the same touchpoints that shape retention more broadly. If you are still mapping out which screens your product needs, our overview of top fantasy sports app development features covers the core flows these animations attach to.
Lottie files are light, but a careless one can still drop frames on a budget Android phone, which matters a lot in markets where many users run entry-level devices. A few habits keep things smooth.
.lottie files are compressed, they are handy when you ship many animations or need assets packed together.Designers new to the format sometimes ask for a plain-language overview before they start exporting. For Spanish-speaking members of your team, this guide on what Lottie is and when to use it is a handy primer, written in Spanish, that covers the format and typical use cases.
Each platform has a maintained player, and the choice usually follows your app's tech stack.
| Platform | Library | Notes |
|---|---|---|
| Android | lottie-android | Installed with Gradle; includes Jetpack Compose support |
| iOS | lottie-ios | Swift Package Manager or CocoaPods |
| React Native | lottie-react-native | iOS, Android and Windows; web needs an extra package |
| Flutter | lottie (pub.dev) | Pure Dart player, a community port of lottie-android |
| Web | lottie-web, dotlottie-web | SVG/canvas rendering for JSON and .lottie files |
On Android, the lottie-android README describes the library as parsing After Effects animations exported as JSON with Bodymovin and rendering them natively, and it points to the separate Compose documentation for Jetpack Compose projects.
Many fantasy apps are built with React Native to share code between platforms. The lottie-react-native repository shows the basic LottieView usage and explains how to load .lottie files by adding lottie to the Metro asset extensions. Check its README for the current React Native version requirements before upgrading, because recent releases target the New Architecture.
import LottieView from "lottie-react-native";
<LottieView
source={require("./assets/team-locked.json")}
style={{ width: 120, height: 120 }}
autoPlay
loop={false}
/>
Flutter teams usually reach for the lottie package on pub.dev, which loads JSON with Lottie.asset or Lottie.network. It can read zip archives, and dotLottie files work through a custom decoder.
Lottie is not a universal answer. Picking the wrong format can bloat your app or limit what designers can do.
A useful rule: if the animation is decorative and tied to a UI state, Lottie is a strong default. If it is photographic, deeply interactive or part of the game loop itself, look at the alternatives first.
The core players (lottie-android, lottie-ios, lottie-web and lottie-react-native) are open source. Check the license of each individual animation file you download, since marketplace assets have their own terms.
JSON is universally supported and easy to inspect. dotLottie is compressed and can bundle several animations and assets, which helps when you ship many of them. Confirm that your chosen player supports .lottie before switching.
Keep live data in native views and use Lottie for the surrounding motion. Text inside an animation can be changed in some players, but native text is easier to localize, update and keep accessible.
If you are planning a new product and want animation decisions built into the design from day one, our team covers this as part of fantasy cricket app development, from onboarding flows to the moment a user locks their final eleven.