Onomastics
Onomastics, also known as onomatology, is the study of names, and usually refers to its etymological aspects,like figuring out where they came from and how they evolved.
Not to be confused with Onomasiology (the means of expressing concepts).