Every question of how to make an app like spotify needs a detailed understanding of application’s complex structure. In Spotify as a music library-app it has certain fields of development.
There are a few reasons why users choose online streaming over the the downloads of a tile document. One of the main advantages of streaming over the simple downloads is the absence of need to download the audio file in MP3, FLAC, Apple Lossless etcetera; moreover, if it does not require time for downloading - it could be easily turned on within several seconds. Pretty memory and time saving, isn’t it? However, this kind of convenience would need a specific audio format - the one that creating an app like Spotify would need. M3u8 is the appropriate format you can stream your music in. The peculiar thing about m3u8 - for playing a song it actually bitrates it into many “packets”, each of them lasts a certain time - so now you know why sometimes when your internet connection drops, the son keeps on playing till it actually stops somewhere in the middle.
Also, the only thing that streamers are not very great with yet is played music’s quality; formats like Lossless or FLAC would take an eternity to stream (because of their size), so the standard MP3 comes into play. The quality of the MP3 your player provides might as well vary - for instance, Spotify lets us listen to the favorite tracks at 160 kbit/s, increasing it to 320 kbit/s once you become a paid subscriber. Fairly to admit, 160 kbit/s is a pretty okay option for the Earpods users, but the better are the headphones, the more picky with music’s superiority you get.
Read about Spotify’s essentials and the cost of having Spotify built in article “How to develop an Music streaming app Like Spotify?”