NoSleep.js seems to work in iOS 11 and it reportedly works on Android as well.
Old answer
This is a simple HTML-only method to do that: looping inline autoplaying videos (it might also work in Android Chrome 53+)
<video playsinline muted autoplay loop src="https://rawgit.com/bower-media-samples/big-buck-bunny-480p-30s/master/video.mp4" height=60></video>
See the same demo on CodePen (includes a stopwatch)
Notes
- Avoid loading a big video just for this. Perhaps make a short, tiny, black-only video or use
- To make it fully work, the videos needs to be always in the viewport or you need to start its playback via JS:
video.play()