When solid bodies contact and slide against each other, the frictional phenomenon occurs. The origin of the related frictional force is studied by assuming the existence of two clean crystal surfaces, which follows the current experimental trends. This study theoretically clarifies the atomistic origin of the frictional force intrinsically generated by the molecular interactions between the constituent atoms of solids, but not the force extrinsically generated by surface asperities, the existence of foreign atoms, etc. Furthermore, this study assumes that the constituent atoms of the two contacting surfaces interact with each other due to the interaction potential. This study found that there are two origins: atomistic locking and dynamic locking. Atomistic locking occurs when the configuration of the atoms on a contact surface continuously changes with the sliding distance and when the interatomic potentials have an arbitrary strength. In contrast, dynamic locking occurs when the configuration discontinuously changes due to the dynamic process and if the interatomic potential is stronger than a specific given value. A criterion is derived for the occurrence of dynamic locking. From studying various systems, it can be seen that dynamic locking is unlikely to occur in realistic systems. The frictional forces due to atomistic locking are calculated for \ensuremath{\alpha}-iron. One other important finding prior to the experiments is that certain unique cases exist where the frictional force exactly vanishes if completely clean solid surfaces are prepared.