If you mean conscience as it a feeling of right from wrong, it basically goes back to survival and the development of social groups.
An individual living in a social group is much more likely to survive than one that goes it alone. And an individual that has antisocial behaviour will be ejected from the group reducing its chances, So there would be a natural progression of animals that do consider others and live by the social rules staying in the group spreading their genes and the ones the don't being ejected and not thriving.
A member of a group that shares food we be welcome in the group, one the steals gets ejected. So we have this constant play in our brains, we want to do whats good for us, but we also want to protect the group and protect our status in it. this is where the origins of conscience come from.
Fair points, although there are lots of examples of psychopaths who do quite well for themselves in society while maintaining a hatred for both society and the individuals within it.