The crossbow played an important role in the late Medieval period. The crossbow was really the first hand-held weapon that could be used by an untrained soldier to injure or kill a knight in plate armour. The most powerful crossbows could penetrate armour and kill at 200 yards. Crossbows are easier to aim than longbows because the crossbowman doesn't have to use a hand to hold the string back while aiming. On a similar note, a crossbow can be loaded long before the bowman might need to shoot. In this way, the bowman would be able to shoot immediately if surprised. Crossbows require less upper body strength to operate as well. One can use both arms to span (draw back) a crossbow. Crossbows do, of course, come with a price. That price is in efficiency and in the firing rate.
No bow is perfectly efficient, but Medieval crossbows were particularly inefficient. The reason for this is that the draw length and the lathe (also called a prod) of crossbows are short. So even though a crossbow may have a great deal of stored energy when spanned, the tips of the lathe do not have enough time to reach the maximum velocity, so the amount of stored energy is not transferred fully to the bolt. It is the lathe tip velocity that determines the speed of the bolt th
at is loosed.
A lthough there are working examples of Medieval crossbows, there are no working examples of Medieval longbows, so a direct comparison between the two cannot be made. Hence, the only data I can draw on for longbows is either from historical evidence or from reproductions of Medieval longbows. It is my belief that while the range of longbows changed very little from the 11th. century through Medieval times, the range of crossbows certainly did increase. Historical evidence would indicate that in the hands of a well-trained longbowmen, distances of 250-350 yards were commonly attained. A few modern archers have regularly achieved distances of 350-450 yards with reproduction longbows. Inigo Simot loosed an arrow 462 yards 9 inches in 1914, and there is a claim of someone loosing an arrow 482 yards with a longbow.
At the time of the battle of Crecy (1346 C.E.), the English longbow almost certainly had a greater range than the crossbow used in field combat. Throughout the Medieval Period though, crossbows became more powerful. Sir Ralph Payne-Gallwey loosed a bolt from an actual Medieval crossbow spanned with a cranequin and achieve a cast of 490 yards. The ordinary 15th. century crossbow would likely cast a bolt 370-380 yards. These crossbows would surely outperform almost any longbow in terms of distance, but the accuracy of the crossbow at those ranges would likely be poor at best.
With range out of the way, power is an even more difficult subject to breach. In general, arrows weigh more than bolts, so they have a larger momentum (force) associated with them. However, a late Medieval crossbow bolt has a higher speed associated with it, which will overcome the lower mass. (the the force being equal to the mass times the square of the velocity). Both longbows and crossbows were capable of penetrating all but the thickest plate maile armour, but my understanding is that the heavy crossbow was the main driving force leading to heavier and heavier plate maile armour. At point blank range, the crossbow almost certainly had greater penetrating power than a long bow. By the 15th century, and possibly earlier, it is safe to say that heavy crossbows (such as a windlass spanned crossbow) were more powerful than longbows. The common crossbow probably wasn't much more powerful though