I would say, historically, they served for one of two reasons:
1) To tie two families together and thereby increase the political or material assets of the families;
2) To establish a clear way for property to be passed down from generation to generation. Theoretically, all sons borne in wedlock were fathered by the husband.
Today, I think those two reasons don't really apply. Marriage serves as a form of social stability. Married couples are able to pool their various resources to improve their lives and the lives of their children.
Preserve mankind from evil and degeneracy.