Glasir – an open source PHP/HTML5 media player

Glasir is an open source PHP/HTML5 media player for a personal music collection of unlimited size. For use with Chrome, Firefox, and Android phones. It’s a project that I developed and open sourced for people to install it on their personal web servers and point it at a music folder.


Glasir is the name of a tree which is “the most beautiful among gods and men”, according to Norse mythology, bearing golden leaves located in the realm of Asgard, outside the doors of Valhalla (source). The folder structure presented in the Glasir music player is supposed to resemble the golden leaves of the Glasir tree.

Glasir – The Music Player Website

The Glasir website was developed as an alternative to systems like Subsonic and Grooveshark[1], which require a paid license to index your local files[2].

[1] Grooveshark offers free music and playlists. Subscribers to Grooveshark Anywhere can get commercial free music for phones and mobile devices for $9 per month (at the time of writing).

[2] Subsonic is a free music server which requires a single payment/donation for a premium license. Mentioning it here is not a complaint, but a sign of respect to a wonderful cross-OS music system.

Glasir is open source and completely free, although the development and updates are more limited than a paid system. Its intended purpose is to scan your media folder for mp3 and ogg files, such as music, then it will index those files using their ID3 properties and display the information to you. You can then create a playlist and play your songs in order or shuffle them.


User not logged in.

User not logged in

User logged in. Playlist shown.

User logged in. Playlist shown


Glasir is developed for Google Chrome (or Linux Chromium) and Firefox. While it may work in other browsers, it’s not specifically targeting them at this point in the development process. It also seems to work with Firefox mobile and Opera Mobile, to a limited extent.

Future of Glasir

Future development of Glasir will include various features depending on the availability within the HTML5 specification. The github notes about functionality include these possibilities:

--Volume Buttons--

Up and down independant of the system volume (mute not necessary)

--Export playlist to zip--

Playlists are great but, what about taking a copy with you?

--Cover Art--

If the folder has cover art, then try to use that.

Check the album name, artist, and song against a website like Amazon to find the cover art.

--Custom playlists/Searches--

- Songs listened to most

- Songs listened to least

- Artist

- Album

- Year

- Song name

Low priority


Firefox includes a method to obtain visualization information from the audio tags.

Include the functionality only for Firefox users. Add more visualizations as other browsers adopt the functionality.

--Beats per Minute--

Process the audio in the database to determine the BPM for each song.

This requires background processing. Load the BPM into the database to allow custom playlists, like "Fast Songs", "Slow Songs", etc.

--Song Preview--

If the player is paused and the user hovers over a song in

the playlist then play a short sample (10 seconds?)

You can find more information and the source files here if you’re interested in testing it out. The project is open for new developers too, so if you like the idea and think you can add something to the project, then please join.

Latest Posts