In a case study, the Android Developer Relations team today detailed recent improvements and optimizations made to TikTok for Android.
With over 1 billion users worldwide, TikTok runs on “various network conditions and device specifications.” Its developers use “data monitoring, peer app comparison and user surveys to track the overall app performance.”
TikTok’s engineering team cites “janky frames, video playback lag, and network issues” as responsible for slowing down the app, and set out to address each. Chiefly, app startup time was reduced by 45% through:
- Refactoring “the app’s startup framework to achieve on-demand loading and meticulous scheduling of components.”
- Using a “background thread to load View components asynchronously.”
- Leveraging “Simpleperf to analyze the code execution time, and Android Studio’s Profiler to monitor the usage of resources such as memory, CPU, and network to optimize I/O, threads, and resource locks.”
To offer a smoother user interface, TikTok simplified the app so that it “only renders what is necessary on screen.” It then “reduce[d] the number of task executions in each frame so that the app can have a steady frame rate.” This resulted in smoothness, which is defined as the “chance of the frame rate being lower than the target value,” getting optimized by 49%.
Meanwhile, playback improvements have resulted in the first frame of a clip appearing 41% faster, with video lag reduced by 27%. This involved work on codecs, optimizing network connections, preloading, pre-rendering, and using “on-device video super-resolution to generate high-resolution frames based on low-resolution video content.”
In all, “active days per user in 30 days increased by 1% as did the average of session duration,” which is notable given TikTok’s scale.
Looking ahead, Google said the TIkTok team has “also been focusing on large-screen devices, including foldable devices.” However, anecdotally, we find that part of the video is often cut off on tall or short displays since the app optimizes for the phone rather than content. Meanwhile, today’s case study did not really touch on the content creation (video recording) aspects of the application.
By constantly optimizing app performance and adapting to the latest Android 13 platform, TikTok has created a more seamless app experience, encouraging more users to discover, create, and share the content they love.
FTC: We use income earning auto affiliate links. More.
Comments