The plot centers around Sandra Bullock who plays Lucy, a lonely fare collector working in Chicago on the elevated railway, also called the El. The high point of everyday is selling a token to a handsome commuter, Peter Callaghan, on whom she has a secret crush. During the Christmas holidays, Lucy sees Peter being mugged and pushed on the railroad tracks and she rescues him from an oncoming train. Peter falls into a coma and Lucy goes with him to the hospital. At the hospital, she fantasizes out loud that she is going to marry Peter. A nurse misunderstands her and thinks she is Peter’s fiancĂ©e. Therefore, Lucy is allowed to see Peter and his family. At first, Lucy is too caught up in the madness and panic of the situation to tell the family the truth and after a while she is too embarrassed to tell the family the truth.
Lucy’s parents have died and she has very few friends; therefore, she comes to love the family and she can’t bring herself to hurt them by telling them the truth that Peter and she only meet that day on the tracks, so he doesn’t really know her at all. Everything is going well until Lucy meets Peter’s brother Jack who questions whether Lucy and Peter are engaged to be married and on top of everything else, while Jack and Lucy are spending time together, Jack starts having feelings for Lucy. Other problems arise when Peter wakes from the coma and can’t remember Lucy at all; however the family thinks that he will remember her once they spend time together. In addition, Peter is convinced by his godfather, Saul that Lucy must be the love of his life if he proposed to her. Therefore, Peter proposes to Lucy again and she says yes even though she has feelings for Jack.
On the day of the wedding, Lucy is still struggling with the lie and her feeling for Jack. However, she shows up at the church to marry Peter. However, she can’t go through with it and confesses the whole thing to the family and tells of her feelings for Jack. While the family talks, she leaves the church unsure of her future. The next day while she is taken tokens from everyone, she sees Jack and the family standing at her window with an engagement ring and a marriage proposal for Lucy. While You Were Sleeping ends with Lucy and Jack happily married in weeding attire on an El train. The tile of the movie comes from Peter asking Lucy when it was exactly that she fell in love with Jack; She answers,” While you were sleeping.” This romantic comedy is funny and heartwarming; plus it will not put movie goers to sleep.