A new study finds that genes are at least part of the reason.
They discovered two specific genes combined with people's perceptions of the world predicted generosity.
In other words , people who found the world threatening were less likely to help others unless they had versions of the receptor genes that are generally associated with niceness.
The "nicer" versions of these genes allow you to overcome feelings of the world being threatening and help other people in spite of those fears.
The study appears in the journal Psychological Science.