The quality of sleep has a great impact on health and life quality. A classification of sleep stage is very important for managing the quality of sleep. This paper presents a method for classifying sleep stages based on the bagged trees classifier with a continuous-wave (CW) Doppler radar. In the experiment, a subject was asked to sleep all night with polysomnography (PSG) to get the labels of the nine features extracted from the radar signals. Four kinds of tree classifiers were selected as the machine learning algorithm to classify wakefulness, rapid eye movement sleep (REM), light sleep and deep sleep. A 10-fold cross-validation procedure was used for testing the classification performance. Compared to PSG results, the bagged trees classifier has the best classification accuracy rate among the four classifiers. Using appropriate parameter of the base learner, the accuracy rate can be improved to 78.6%.