First, you must love yourself. It can be challenging to love a person who does not love him/herself. So, love yourself. Know what you deserve and do not deserve. If you know within yourself that you deserve more and better things in life, there you allow yourself to be loved by others.
In order to love and be loved, you have to love yourself first in order to love and be loved by others. How will you do that? Be positive, be optimistic as always, avoid finding faults to anyone you encounter, and accept anyones flaws. Love will be more easier to render to someone if you master yourself to look at the positive sides of every person you will encounter