Incredibly, I haven't been able to find a good entry online comparing these two mathematical structures. Their relative familiarity doesn't make their boundaries less fuzzy. Here is a coarse attempt:
From Wikipedia,
In mathematics, a function is a relation between a set of inputs and a set of permissible outputs with the property that each input is related to exactly one output.
A homomorphism is a structure-preserving map between two algebraic structures of the same type (such as two groups, two rings, or two vector spaces).
Based solely on these definitions it would seem that:
A function is injective (?) - this sounds incorrect. Yet, from general use, it would seem that both functions and homomorphisms can be injective or surjective, bijective, or neither.
Functions seem more limited in their algebraic structure, while the maps in homomorphisms can be defined more broadly.
Homomorphisms seem to encompass relations between a broader range of algebraic structures.
The property of homomorphisms $\varphi(a\circ b)=\varphi(a)\circ\varphi(b)$ is not necessarily a characteristic of functions.