Hello,
yes, it is good practice to put at the beginning of file some marker (magic) to allow detect file type by first few bytes of the file content. Many files types uses this (see examples: http://www.garykessler.net/library/file_sigs.html in my opinion some of them are not well chosen and conflict with others – I prefer to put the magic to offset 0).

Milos