The bacterial flagellar motor is a remarkable nanomachine that provides motility through flagellar rotation. Prior structural studies have revealed the stunning complexity of the purified rotor and C-ring assemblies from flagellar motors. In this study, we used high-throughput cryo-electron tomography and image analysis of intact Borrelia burgdorferi to produce a three-dimensional (3-D) model of the in situ flagellar motor without imposing rotational symmetry. Structural details of B. burgdorferi, including a layer of outer surface proteins, were clearly visible in the resulting 3-D reconstructions. By averaging the 3-D images of approximately 1,280 flagellar motors, a approximately 3.5-nm-resolution model of the stator and rotor structures was obtained. flgI transposon mutants lacked a torus-shaped structure attached to the flagellar rod, establishing the structural location of the spirochetal P ring. Treatment of intact organisms with the nonionic detergent NP-40 resulted in dissolution of the outermost portion of the motor structure and the C ring, providing insight into the in situ arrangement of the stator and rotor structures. Structural elements associated with the stator followed the curvature of the cytoplasmic membrane. The rotor and the C ring also exhibited angular flexion, resulting in a slight narrowing of both structures in the direction perpendicular to the cell axis. These results indicate an inherent flexibility in the rotor-stator interaction. The FliG switching and energizing component likely provides much of the flexibility needed to maintain the interaction between the curved stator and the relatively symmetrical rotor/C-ring assembly during flagellar rotation.