I suspect this may be more of a concept / theory question, but, I haven't been able to wrap my brain around what exactly a binary file is.

I've read links such as the below:



But, the piece of the puzzle that's confusing me, is that ALL files are stored as 1's and 0's on a hard-disk, or, in RAM, etc. (i.e. there's no physical engraving of the hex characters "6F" onto a disk platter for example; it's still a binary format that the data is stored in).

So, if all files are stored as binary, then, presumably it's an operating-system, (& filesystem) concept to refer to something as "binary" file?

  • $\begingroup$ A binary file is one which is not a text file. See Wikipedia for more on text files. $\endgroup$ Jul 19, 2018 at 8:53

1 Answer 1


A binary file is a file that is simply not a text file. It means that a bin file has a specific format (mp3, exe, jpg...) and can not be interpreted only as a character sequence. There are many ways data can be formatted and read.

  • 2
    $\begingroup$ A binary file need not have a "specific format". $\endgroup$ Jul 19, 2018 at 11:00
  • $\begingroup$ A binary file is not just a bunch of 0's and 1's, it needs a way to be formatted. $\endgroup$
    – m68k
    Jul 19, 2018 at 11:04
  • 1
    $\begingroup$ If you store a cryptographic key in a file, it's not formatted at all. There isn't any set of allowable formats for files, dictated by the operating system. $\endgroup$ Jul 19, 2018 at 11:07
  • $\begingroup$ Oh ok, I see what you mean. It's clearer this way $\endgroup$
    – m68k
    Jul 19, 2018 at 11:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.