Cyclists shaving their legs is more tradition than anything else--there is a whole industry around creams, soaps, and salves.
However, I'll defer to Sheldon Brown 's explanation for a few acceptable reasons why they do it: To prevent infection when crashing.
To pull off bandages more painlessly after dressing a wound.
To get a massage of the legs without hair pulling.
One reason I've often heard is 'To be more streamlined in the wind'--but
I don't believe it!
bicycles.stackexchange.com/users/23/Dustin Ingram
It's the best way to show off the hard work you've put into developing all those muscles :)
bicycles.stackexchange.com/users/39/Christopher Scott
I've never seen a noticeable difference in wind resistance whenever I've shaved my legs for cycling, though I was never competitive to the point of measuring time in hundredths of a second.
I have found, from painful personal experience
, that road rash from a crash heals much more nicely on shaved skin than hairy legs, mostly because bandages and tape become much easier to remove!
bicycles.stackexchange.com/users/33/Scott
So you can get razor sharp tan lines.
Pesky hair can result in migrating shorts which leads to blurring of the tan line.
And really ... if you are going to look foolish, you might as well just jump RIGHT in.
bicycles.stackexchange.com/users/245/tplunket
I agree with Dustin's answer as the putative reasons usually cited, but I think at some level, it's a mark of the tribe .
Guys figure "if I shave my legs, other cyclists (and even some non-cyclists) will recognize me as a fellow cyclist."
If being a cyclist is an important part of your identity, that'll be important to you.
It is kind of cool to be able to pick someone out and strike up a conversation about cycling just based on their weird tan lines and/or shaven legs.
bicycles.stackexchange.com/users/2152/Adam Rice
Aesthetical reasons trump all else.
Hairy limbs peeking out of tight lycra just look nasty.
Contemplate attached picture to see what looks better, Astarloa's legs or arms?
bicycles.stackexchange.com/users/130/ttarchala
One reason not yet mentioned is that in summer your legs feel cooler.
But I think the No. 1 reason is psychological
- it looks good and all the fast guys do it (sorry ladies, the shaving legs things for girls is so not an issue).
bicycles.stackexchange.com/users/106/Anthony K
There are two additional things that haven't been mentioned yet.
First, road rash is actually made worse by hairy legs.
We all know that when you hit the pavement it acts like sandpaper scraping a layer off your skin.
However, if you have hairy legs the hairs get pulled out by the root as well.
This makes the road rash deeper where your skin actually comes into contact with the ground as well as making the surface area of the wound larger because of hairs that get pulled out around the actual contact area.
And second, while road rash isn't as much of a concern for mountain biking, there's an additional advantage there too.
It's easier to wash the crud off after a ride.
You can just hose your legs off out of your water bottle and watch the dirt come off in rivers.
bicycles.stackexchange.com/users/4239/jimchristie
In addition to the previously mentioned benefits, recent wind tunnel testing performed by Specialized has shown that shaved legs will save about 50 to 82 seconds over a 40km TT...certainly not an inconsequential amount.
Turns out the oft-cited study from 1987 that many use to say that leg hair doesn't affect aerodynamics was performed in a miniature wind tunnel using a fake leg with or without hair glued onto it .
Hardly comprehensive, but only recently challenged.
Interestingly, shaving your arms could save about 19 seconds over 40k, while shaving the beard will only save about 1 second.
bicycles.stackexchange.com/users/11045/Altom
Allegedly, shaved legs make it much easier to apply and remove embrocation, increases it effectiveness, and eliminates the "bugs crawling on skin" feeling when hairs pop back into position.
FYI:
embrocation is an ointment used to heat muscles & joints on chilly days.
bicycles.stackexchange.com/users/2572/keithmo
Common, Am I the only one whose thigh hairs gets pulled while cycling.
Or when cycling on jeans(I know its horrible thing), the ups and downs of hair is just kills me.
Thats the reason I shave.
To be pretty, when I am cycling, no way.
I am cycling, not modeling for the cycles.
(Sorry, guys if I have offended you.)
bicycles.stackexchange.com/users/847/Starx
Cyclists shave their legs for three reasons:1.
To avoid any insect clings in their feet hair2.
Get a better massage3.
For a cool feel during the ride
bicycles.stackexchange.com/users/25711/Adam89
Why do cyclists shave their legs? Is it because of wind resistance?
Why do cyclists shave their legs?
bicycles.stackexchange.com
<technique><performance><body-hair>
bicycles.stackexchange.com/questions/44
bicycles.stackexchange.com/users/29/Johan Dahlin
The consensus seems to be that the main reason male cyclists shave their legs is aesthetic: it looks good, they get a more even tan and they are recognised as cyclists. However, there may be more serious reasons, such as the chafing caused by hair and to feel cooler, especially in summer. Moreover studies show there is a very small aerodynamic advantage. Shaving is mostly due to tradition and aesthetic reasons. Shaved legs display muscle better, allow for a better tanning and are among the distinguishing marks of the cycling community. In the event of a crash or fall, shaved legs may prevent infection. Using bandages is also easier. Moreover, shaving your legs may prevent hair pulling when you are riding or getting a massage. You could also avoid getting insects on your legs. Shaved legs also offer a cooler sensation. Arguably, shaved legs may make you faster, as is decreases wind resistance.
Shaving is mostly due to tradition and aesthetic reasons. Shaved legs display muscle better, allow for a better tanning and are among the distinguishing marks of the cycling community.  In the event of a crash or fall, shaved legs may prevent infection. Using bandages is also easier. Shaving your legs may prevent hair pulling when you are riding or getting a massage. You could also avoid getting insects on your legs. Shaved legs offer a cooler sensation. Arguably, shaved legs may make you faster, as is decreases wind resistance.