Is it haram to have a boyfriend or girlfriend?
Is having a boyfriend haram? But you don't do anything haram with him. You just label each other as boyfriend/girlfriend but treat each other as best friends without doing anything haram
The right question to ask is: “Does it please God and my family to have a boyfriend/girlfriend, is it beneficial to my own soul, and is it good for my future?” If you read the Quran and the books of hadith, you will not find anything that explicitly forbids such a relationship. But there is a lot more to it than that.
First, note that I would be willing to accept the excuses of a person who involves themselves with such relationships. But that is the problem; such relationships have to be excused. They are not noble and admirable things to participate in, and all pious and self-respecting Muslims would do their best to avoid them except under the most extreme circumstances.
By calling someone your boyfriend/girlfriend, you mean that you have an exclusive romantic relationship with them. It is like pretending to be married without actually marrying and without intending to do the physical acts associated with marriage. The intention is to get the companionship and sense of being loved and supported that we get from a romantic partner without going through the difficult process of finding out if your life circumstances will enable you to be together, and finding out whether your family approves of the person and whether their family approves of you. You cut out their involvement, and the involvement of the rest of reality in order to jump right into the romance part.
It is almost needless to say how foolish and dangerous that is. If you are a woman, a husband is forced to be nice, kind and considerate toward you even when he does not feel like it, even when you do not deserve it, because he is not only responsible to you but to your family and his family. He has to live up to the image of a husband. But a random male with whom you develop a romantic relationship is not answerable to anyone but himself. Many people in the West who enjoy the freedom of being able to jump into romantic relationship after relationship end up being scarred for life by the extreme maltreatment (I do not mean physical abuse, but emotional abuse and negligence) of their partners, or end up being the abuser themselves without intending it, because there is nothing to humanize their relationship and control it as it happens in marriage.
Marriage is meant to be an election. You need to appreciate the purpose of marriage before you are able to realize what is so wrong with boyfriend/girlfriend relationships. See my essay: The Point of Marriage in Islam (and the Problem with Romantic Relationships Outside of Marriage)
An intelligent, self-respecting and wise Muslim woman will consider it extremely beneath her to grant her love to a man who has not gone through the process of proving himself to be a worthy husband. She would be giving something away for free that is meant to be extremely valuable and precious; a foolish decision that shows her lack of understanding. It is a sign that there is a serious problem with her that is making her desperate. Sometimes, maybe often, the blame is with her family. By depriving her of love and sense of having an honored status in her family, she is forced to seek that in men outside her family. But even in such cases part of the blame is on her; a better woman would put up with her family’s failings and lack of love and endure patiently until God enables her to have something better.
The same of course applies to some men who seek such romance.
I know such relationships can be a great temptation. But our task is to resist them the way we resist all other temptations until God changes our situation and we are able to enjoy the pleasures of romance in the normal way through marriage.