Fitbit devices use a 3-axis accelerometer to understand your motions. An accelerometer is a device that turns movement (acceleration) into digital measurements (data) when attached to the body. By analyzing acceleration data, our devices provide detailed information about frequency, duration, intensity, and patterns of movement to determine your steps taken, distance traveled, calories burned, and sleep quality. The 3-axis implementation allows the accelerometer to measure your motion in any way that you move, making its activity measurements more precise than older, single-axis pedometers.
Fitbit devices have a finely tuned algorithm for step counting. The algorithm is designed to look for motion patterns that are most indicative of people walking. The algorithm determines whether a motion's size is large enough by setting a threshold. If the motion and its subsequent acceleration measurement meet the threshold, the motion will be counted as a step. If the threshold is not met, the motion won’t be counted as a step. Other factors can create enough acceleration to meet our threshold and cause some over counting of steps, such as riding on a bumpy road. Equally, it's possible for the algorithm to undercount (not meet the required acceleration threshold). Examples here include walking on a very soft surface such as a plush carpet.
For information about specific conditions see How accurate are Fitbit devices?