Many people view marriage as just a religious function, but it's really a legal one. It's why you have the "power vested in me" by whatever is the governmental law authority of the area.
Many people now just do the civil ceremony and skip the religious ceremony. It was interesting to see all the couples outside the government office waiting to get married on whatever day marriages were performed.