A God-given Gift
Marriage itself is a special God-approved agreement or covenant between one man and one woman, as in the case of Adam and Eve (Genesis 2:18, 21 - 24). The Eternal made possible this special relationship after creating Eve especially for Adam.
It should be noted that although a number of Old Testament individuals had more than one wife, the New Testament reaffirms God's original intent of having only one man and one woman united in marriage.
And the Lord God said, "It is not good that the man should be alone. I will make a helper compatible for him." . . .
And Adam said, "This is now bone of my bones and flesh of my flesh. She shall be called Woman because she was taken out of Man." For this reason shall a man leave his father and his mother, and shall cleave to his wife - and they shall become one flesh (in marriage) (Genesis 2:18, 23 - 24, HBFV).
The Covenant Before God
The marriage covenant is a commitment to live together to maintain a home, to share sexual intimacy, and (many times) to produce children and raise a family. This union is intended to be permanent and should not cease, ideally, until death.

The Bible never says anything specifically about being joined in matrimony "in the heart." If this means emotional affection is required, this often came after the ceremony, not before (cf. Genesis 24:67). Consensual agreement must be involved before a marriage occurs.
A Contract Before Witnesses
In order for a valid marriage to occur, in God's eyes, some kind of verifiable contract or license needs to be signed before witnesses. A couple's feelings of wanting to be together, forever, are not enough of and by themselves.
Matrimony is not only an individual contract that concerns the couple in question, which is often a popular notion in individualistic Western countries like America, it also impacts society in general.
It should be noted that a couple who lives together and has sex, without the benefit of making their vows of love publicly known and official, is living in sin (an act known as fornication in the King James Translation). A sexual relationship, even if it ultimately culminates in a marriage, is still wrong in the sight of God.
For Further Study
Important scriptures related to marriage include Genesis 2:18, 21 - 24, Malachi 2:14 - 15, 1Corinthians 7:1 - 17, Ephesians 5:22 - 33, Colossians 3:18 - 19, Hebrews 13:4, and 1Peter 3:1 - 7 among many others.
Keep your eyes wide open
before marriage, half shut afterwards.
(Benjamin Franklin, 1706 - 1790)