There is no doubt that relationships between men and women who are not their mahrams (close relatives who one can never marry) are haram (unlawful).
We have previously explained on our website who is the religiously committed woman who a man should look for when he wants to get married.
It is on this basis that the wise man should choose the one who will accompany him in this world. It was narrated from ‘Abdullah ibn ‘Amr that the Messenger of Allah (blessings and peace of Allah be upon him) said: “This world is temporary joys, and the best temporary joy of this world is a righteous wife.” Narrated by Muslim, 1467; Ibn Maajah, 1855, with the wording, “Indeed, this world is no more than temporary joys, and there is no temporary joy of this world that is better than a righteous wife.”
It was narrated from Abu Hurayrah (may Allah be pleased with him) that the Prophet (blessings and peace of Allah be upon him) said: “Women may be married for four things: their wealth, their lineage, their beauty and their religious commitment. Choose the one who is religiously-committed, may your hands be rubbed with dust (i.e., may you prosper).”
Narrated by al-Bukhaari, 4802; Muslim, 1466.