It's used in the same way as the English word, to describe something or someone that is preferred above others.
Here are some examples:
* "Mi color favorito es azul." (My favorite color is blue.)
* "Este es mi restaurante favorito." (This is my favorite restaurant.)
* "Su canción favorita es 'Bohemian Rhapsody'." (Her favorite song is "Bohemian Rhapsody".)
* "El perro de mi amigo es su favorito." (My friend's dog is his favorite.)