How to Size a Mountain Bike
To size a mountain bike, measure the height for the seat tube by standing up straight with your back against a wall, using a tape measure to calculate the distance your pubic bone and the floor. Once you have your measurements, use them as a guideline to find the right size bike. For example, a small bike will typically have a 14-16 inch seat tube, which will generally fit those between 5 feet 4 inches and 5 feet 7 inches tall.
Know the guidelines. Many bike companies have basic size ranges that you can choose from. Different companies may vary in their ranges, so a small bike from one manufacturer may be different in size than another. XS bike: 13-14in (generally for those between 5ft and 5ft 4in) S: 14-16in (generally for those between 5ft 4in and 5ft 7in) M: 16-18in (generally for those between 5ft 7in and 5ft 10in) L: 18-20in (generally for those between 5ft 10in and 6ft 1in) XL: 20-22in (generally for those over 6ft 1in) Keep your positioning on the bike in mind. When you sit on a bike, your shoulders should be relaxed and your elbows slightly bent. Make sure your knees are slightly bent when you're at the bottom of your downstroke. If you don't feel comfortable on the bike, consider changing to a different size. Adjust your shifters and brake levers so your wrists are neutral when you have your fingers on them. Know how bikes vary. Sizing systems vary across companies, but they also vary across bikes. If you're online searching for your next gem, keep this in mind. Here are some basics: Road, cyclo-cross, and hybrid bike sizes generally run 3-4" bigger for the same rider height, like in the chart above. If you're looking at one of these, adjust as necessary. Hardtail bikes and full-suspension bikes are sized the same. The main differences are cost and what kind of roads they can handle. Full-suspension bikes have much better shocks and can handle more aggressive riding. The hardtail is more versatile and lighter, however, in trade. Measure your inseam. To know what size bike is right for you (what length seat tube you need), start with your inseam. To do this: Stand up straight with your back against a wall, a book between your legs like the bike's seat. Use a tape measure to calculate the distance between your pubic bone and the floor. Measure your bike's seat tube, if applicable. If you already have a bike, you'll want to know if it's the right size for you. Here's how to measure your frame: Find the top of the seat tube (where the seat clamp meets the post). Measure from that point to the middle of the axle that holds the crank arms together. That number is your seat tube length. Does it match your ideal size? Check out the basic sizing system below if you're considering buying. Do the standover test. This is a pretty generic test to see if your bike is the right height for you. That number you got when you measured your pubic bone to the floor? You want that to be about 2" greater than the height of your bike at the top tube (the one that goes from the seat to the handlebars). To execute this test, put your leg over the bike's top tube and straddle it. Lift the bike up as far as you can, and have a helper measure the distance between the tires and the ground. Find your ape index. Once you know how tall your bike should be, you'll need to know where the handlebars should fall into place for your particular torso length. To determine whether you have a long or short reach, you'll need your "ape index." Measure your arm span (fingertip to fingertip) minus your height. A positive ape index (your arm span is greater than your height) means you should consider the next largest size; a negative ape index means you should (your height is greater than your arm span) go for the smaller of the two sizes. This is a great indicator, especially, if you're between sizes. Height and inseam should be your main two considerations; this should seal the deal. If for some reason you're still in doubt, go smaller. It's easier to bail on a smaller bike than a large one. To get specific, find your ideal top tube length. This is done by measuring your torso length and arm length. Here's the specifics: Stand up with your back straight against a wall. Measure from your knuckles to your collarbone. Measure from your pubic bone (the same place as before) to the hollow at the base of your neck. Add the results together and divide by 2. Take that number and add 4. This is the ideal length of your top tube. To clarify, say your arm length is 24 and your torso length is 26. That's 50 / 2 = 25. 25+4 = 29. 29 is then what the length of your top tube should be. Adjust your seat height. With your measurements, adjust the length of the seat tube. You'll need a tape measure and a wrench. Here's how: Place the end of the tape measure where the pedal crank attaches to the bicycle. Stretch the tape measure out to the seat height calculated using your inseam. Use a wrench to loosen the bolt that holds the seat post. Swivel the seat post up or down into the proper position. Use a wrench to tighten the bolt. Adjust the seat so that the saddle's widest part is level with the upper end of the tape measure. Adjust the handlebars. Loosen the bolt at the base of the handlebars. Use a standard wrench, turning to the left. To adjust the handlebars: Lean forward so your upper back makes a 90-degree angle with your upper arm. Keep your forearms at a 45-degree angle to the handlebars. Raise or lower the handlebars so they're level with the saddle. Tighten the handlebars. Use a wrench to tighten the bolt around the handlebar stem. Adjust the seat tilt. You want your saddle to be completely level. A minority of people prefer it tilted up or down, but most ride best with a level seat. Two things to keep in mind: Tilt the saddle up or down so that your pelvis is level when you sit on the saddle. Tilt the saddle so that you do not slide forward or backward when sitting on the saddle. Test the adjustment. You wouldn't buy a car without giving it a test drive, right? You should never have to swivel your hips, stretch out your arms, tilt to the side, or ever make yourself even slightly uncomfortable. Here's how to test your bike: Sit on your bicycle with your shoes on. Your hips should be facing straight forward. Position the pedals so that one pedal is at the lowest point in its rotation. The pedal will be as close to the ground as possible. Place one foot on the low pedal. Your knee should be bent slightly. Your heel should rest on the pedal. Lean onto the handlebars, keeping your elbows slightly bent. If anything doesn't feel 100% comfortable, readjust as necessary. 
Know the guidelines. Keep your positioning on the bike in mind. Know how bikes vary. Measure your inseam. Measure your bike's seat tube, if applicable. Do the standover test. Find your ape index. To get specific, find your ideal top tube length. Adjust your seat height. Adjust the handlebars. Adjust the seat tilt. Test the adjustment. 