PROBLEM TO BE SOLVED: To provide a sensor device capable of preventing an amount of data to be sampled from being increased, while appropriately sampling motion data for precisely analyzing walking states and running states of a user.SOLUTION: CPU 10 of a sensor device 1 is configured to execute high-speed sampling of motion data at a prescribed high-speed sampling frequency, and to execute low-speed sampling of the motion data at a low-speed sampling frequency lower than the prescribed high-speed sampling frequency. The CPU roughly analyzes the motion data sampled at the low speed and, when results of the rough analysis of the motion data such as a pitch and stride that are analyzed roughly, are changed exceeding a set prescribed range, executes the high-speed sampling for sampling the motion data at the prescribed high-speed sampling frequency for a prescribed time T1.