Why do deer have antlers?

With the exception of the Chinese water deer, which have tusks, all male deer have antlers.

Sometimes a female has a small stub. The only female deer with antlers are reindeer. 

Antlers grow as highly vascular spongy tissue covered in a skin called velvet. Before the beginning of a species' mating season, the antlers calcify under the velvet and become hard bone. 

The deer rubs off the velvet, leaving dead bone which forms the hard antlers. After the mating season, the pedicle and the antler base are separated by a layer of softer tissue, and the antler falls off.

One way that many hunters are able to track main paths that the deer travel on is because of their "rubs". The deer rub trees to deposit scent from glands near the eye and forehead and physically mark territory.

During the mating season, bucks use their antlers to fight one another for the opportunity to attract mates in a given herd. 

The two bucks circle each other, bend back their legs, lower their heads, and charge. The tines on the antlers create grooves that allow another male's antlers to lock into place. This allows the males to wrestle without risking injury to the face.