If you are running iOS 10 on your iPhone, iPad or iPod touch, then you can play any audio or video (including Youtube) on Safari and keep its sound playing in the background even when you exit the app. To do so all you need to do is open any audio or video streaming webpage and play the song, audio clip or video. Once it starts playing you can simply click the home button and return to the homescreen. When you are on the homescreen the audio will be playing the background while you will be able to launch any app and use it while listening to it. You can even lock your device without worrying about the audio stopping.
There’s a minor difference when it comes to playing video’s sound in the background than an audio clip. The audio clip will automatically keep on playing when you exit Safari. However in the case of a video the sound will stop. To start it you have to pull up the Control Center and then slide to access the music player screen. There you simply have to tap on the play button and the audio will start playing. You can then go on and open any app and keep enjoying the audio from that video.
This is not a new trick and has been around since the days of iOS 9 and perhaps before that. It is good to see we can still do it in iOS 10.