Be sure you have a pump, tire levers, and a spare tube of the right size or a patch kit. If you have nutted axles, you will need (usually) a 15mm, or an adjustable wrench. If you have quick-release axles, be sure you know how to tighten them properly when you reinstall the wheel.
To remove the wheel from the bike, you will probably need to disconnect the brake cable or open the brake quick-release, so the tire can clear the brake pads; and, for the rear wheel, shift the chain into the smallest gears. When the wheel is removed, set the bike on the left side, with the chain up.
Make sure all the air is out of the tube: roll it on the ground with the valve open.
Make sure the valve is not stuck under the bead: push it up in the rim.
Make sure the tire is not stuck to the rim: work it side to side.
1. Remove one tire bead from the rim.
Starting opposite the valve, insert the smooth end of one tire lever under the bead, pointing up.
Wiggle the lever to make sure it’s not pinching the tube, and lever the bead off the rim.
With your other hand holding the wheel firmly and the tire against your chest, hold the lever tightly, up near the bead, with the other end pointing down at the axle, and pull it toward you. If it gets stuck, push it away from you. If the bead slips back onto the rim while you slide the lever, hold the tire with your other hand, pressing down where the bead is off the rim.
If the lever won’t slide, hook the other end of the lever on a spoke, and do the same with another lever on the next spoke on the same side. Use the third lever to slide the bead off.
Slide the lever all the way around — don’t use your fingers: the rubber can be sharp.
2. Pull the tube out, starting opposite the valve.
Lift the bead back over the tube at the valve, and pull the valve out of the rim.
Try not to turn the tube, or the wheel, around, to help find the cause.
3. Find what caused the flat.
Pump the tube up until it expands to about twice its size.
Holding it near your face, listen and feel for air escaping. Note where the hole is, then hold the tube next to the wheel and tire, with the valve by its rim hole, so you can find the cause in the tire or the rim.
If the hole is on the inside of the tube, check the rim strip, If the hole is on the outside of the tube, check the tire for a piece of glass or a thorn.
If there are two holes together (like a snakebite) on the outside of the tube, the problem was under-inflation. Check the rim for a dent that would cause the brake pad to touch the tire in that spot, causing a blowout down the road.
If you can’t find a hole in the tube, check the valve: wiggle it and look around the base for a cut (especially if it was crooked in the rim), or put a bit of spit on the end to see if it leaks. If you still can’t find the hole, dunk the inflated tube in water. If the hole is a big rip, you may need a new tire.
4. Put the new or patched tube in the tire.
Inflate the tube slightly, but not enough to expand it.
Lift the bead over so you can see the valve hole, and put the valve in it.
Lift the bead back over the tube, and tuck the tube evenly into the tire all the way around.
5. Put the bead back on the rim
Make sure the valve is straight, and that it is not stuck under the bead: push it up in the rim.
Use your fingers, not the lever, so you don’t pinch the tube; Starting at the valve, push the bead onto the rim most of the way around on both sides.
Let all the air out of the tube. With the valve at the bottom and the unfinished part facing you, push the last part of the bead onto the rim:
Make sure the tube is not pinched under the bead — tuck it up into the tire with your finger or a lever. Hold the back side of the rim with your fingers and push with your thumbs on both sides, right where the bead crosses the rim. If the very last part is hard, try rolling the tire over the rim with the palm of your hand.
6. Pump the tire up.
Inflate part way, until the tire just holds its shape.
Make sure the bead is seated on the rim: look at the seam on the tire just above the bead; it should be an even distance from the rim all the way around. If it’s not, push it into place with your hands.
If the bike has no brake release, put the wheel on now so you can squeeze the tire between the brake pads.
Finish pumping the tire to the correct pressure and spin the wheel to double-check that the tire is seated evenly, and the wheel is centered between the brakes.