Property A was introduced by Yu as a non-equivariant analogue of amenability. Nigel Higson posed the question of whether there is a homological characterisation of property A. In this paper we answer Higsons question affirmatively by constructing analogues of group cohomology and bounded cohomology for a metric space X, and show that property A is equivalent to vanishing cohomology. Using these cohomology theories we also give a characterisation of property A in terms of the existence of an asymptotically invariant mean on the space.