# Play certain frames and loop it

**URL:** <https://forum.lottiefiles.com/t/play-certain-frames-and-loop-it/2288>\
**Category:** Lottie in Mobile\
**Created:** [February 18, 2022, 2:43am UTC](https://forum.lottiefiles.com/t/play-certain-frames-and-loop-it/2288 "2022-02-18T02:43:34Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![surya](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.lottiefiles.com/surya/32/1586_2.png) [@surya](https://forum.lottiefiles.com/u/surya)\
**Post date:** [February 18, 2022, 2:43am UTC](https://forum.lottiefiles.com/t/play-certain-frames-and-loop-it/2288/1 "2022-02-18T02:43:34Z")

</div>

Hello! I have a 10 seconds animation and I’m thinking of just playing from 2s to 6s and loop it. Anybody know how to control this in Lottie?

I am building stuff for a mobile app so I thought of asking this under ‘Lottie in Mobile’

---

<div class="post-metadata">

**Author:** ![koden.u8800](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.lottiefiles.com/koden.u8800/32/1214_2.png) [@koden.u8800](https://forum.lottiefiles.com/u/koden.u8800)\
**Post date:** [February 18, 2022, 6:25pm UTC](https://forum.lottiefiles.com/t/play-certain-frames-and-loop-it/2288/2 "2022-02-18T18:25:58Z")

</div>

Hello.  
In iOS library you can use `AnimationView.play(fromFrame: AnimationFrameTime?, toFrame: AnimationFrameTime, loopMode: LottieLoopMode?)` method. On other platforms you can find something similar.
