The objective was to determine the effects of sleep or lying deprivation on the behavior of dairy cows. Data were collected from 8 multi- and 4 primiparous cows (DIM = 199 ± 44 (mean ± SD); days pregnant = 77 ± 30). Using a crossover design, each cow experienced: 1) sleep deprivation implemented by noise or physical contact when their posture suggested sleep, and 2) lying deprivation imposed by a grid placed on the pen floor. One day before treatment (baseline), and treatment day (treatment) were followed by a 12-d washout period. Study days were organized from 2100 to 2059. During habituation (d -3 and -2 before treatment), baseline (d -1), and trt (d 0), housing was individual boxstalls (mattress with no bedding). After treatment, cows returned to sand-bedded freestalls for a 7-d recovery period (d 1 to 7) where data on lying behaviors were collected. Daily lying time, number lying bouts, bout duration, and number of steps were recorded by dataloggers attached to the hind leg of cows throughout the study period. Data were analyzed using a mixed model in SAS including fixed effects of treatment (sleep deprivation vs. sleep and lying deprivation), day, and their interaction with significant main effects separated using a PDIFF statement (P ≤ 0.05). Interactions between treatment and day were detected for daily lying time and the number of bouts. Lying time was lower for both treatments during the treatment period compared to baseline. Lying time increased during the recovery period for both lying and sleep deprived cows. However, it took 4 d for the lying deprived cows to fully recover their lying time after treatment, whereas it took the sleep deprived cows 2 d for their lying time to return to baseline levels. Results suggest that both sleep and lying deprivation can have impact cow behavior. Management factors that limit freestall access likely reduce lying time and sleep, causing negative welfare implications for dairy cows.