Since sleep problems, like sleep apnea, may pose a serious health concern, the quality of a person’s sleep is a good indicator of overall wellbeing. It is then crucial to continuously monitor people when they are sleeping, especially if they have cardiac or respiratory conditions. The goal of the present paper is to show how to extract physiological parameters from accelerometric signal processing during sleep by applying a non-invasive technology. Using an accelerometric device located under the mattress, we demonstrated the possibility of extracting heart rate and respiratory rate, and then how to use the same signal to implement an automatic algorithm to recognize apneas and, more generally, different activities. The proposed automatic approach has shown good accuracy and dependability, and it may be a useful tool for preventing significant harm during sleep.