A rotary tool is provided with a mode selecting part that selects one operating mode from a predetermined plurality of operating modes when a mode switching button is pressed. The plurality of operating modes include: a first auto stop mode where a motor rotates only for a first time period after an impacting operation is detected; and a second auto stop mode where the motor rotates only for a second time period which is shorter than the first time period after the impacting operation is detected.