Binary functions are a generalisation of the cocircuit spaces of binary matroids to arbitrary functions. Every rank function is assigned a binary function, and the deletion and contraction operations of binary functions generalise matroid deletion and contraction. We give excluded minor characterisations for the classes of binary functions with well defined minors, and those with an associated rank function. Within these classes, we also characterise the classes of binary functions corresponding to matroids, binary matroids and polymatroids by their excluded minors. This gives a new proof of Tutte's excluded minor characterisation of binary matroids in the more generalised space of binary functions.