Adjust the ceiling fan to the highest speed setting.
Purchase a capacitor-stepped wall control from a hardware dealer. Do not purchase a wall-dimmer. They look very similar but the wall-dimmer is not designed for this task.
Turn off the electrical power for that room from the main circuit breaker box. Double check the power is actually off by trying to turn on the fan.
Remove the wall plate for the fan on/off switch by unscrewing the center screw.
Unscrew the switch at the top and bottom and pull it away from the circuit box with your fingers.
Unscrew the wire caps and, if necessary, unscrew the grounding wire from the circuit box. If the end cap will not come off, cut the wires away from the cap and strip a 1/4-inch of insulation away from the wires. Take the switch away.
Match the color-coded wires on the speed control to the proper wires in the circuit box. Hold the copper wire of the matching wires next to each another and screw the end cap onto them. Confirm that a solid connection is made by gently attempting to pull the wires away from the cap. Do this for all wires. Screw the speed control grounding wire to the proper connection in the circuit box if necessary.
Place the speed control into the circuit box and attach it with the top and bottom screws.
Hold the wall plate in place and attach it back to the circuit box with the center screw.
Turn the power back on at the main circuit box and test the switch to ensure it is operating properly.