Elliot Richards (Brendan Fraser) is a geeky and overeager man working a dead-end job in a San Francisco call-center. He has no friends and his co-workers who manipulate him, know he will do anything for acceptance. He has a crush on his colleague, Alison Gardner (Frances O'Connor), but lacks the courage to ask her out. After Elliot is ditched at a bar while trying to talk to Alison, he says that he would give anything for Alison to be with him. Satan (Elizabeth Hurley), in the form of a beautiful woman, offers to give Elliot seven wishes in return for his soul.
As a test, he wishes for a Big Mac and Coke. Satan takes him to McDonalds and places the order. Elliot has to pay for it, because, "there ain't no such thing as a free lunch." After taking Elliot to her nightclub in Oakland, Satan convinces Elliot to sign her contract, and delivers further wishes.
Elliot wishes to be rich and powerful, with Alison as his wife. Satan makes him a Colombian drug lord whose wife despises him. Satan points out that he never wished for Alison to love him.
Secondly, Elliot wishes to be emotionally sensitive, but Satan makes him so sensitive he spends much of his time crying over how beautiful the world is, and constantly asks Alison whether he has hurt her. Alison says she wants to be with a man who is strong and shallow, and leaves Elliot for a man who is strong, rude and completely different from the romantic and emotionally sensitive Elliot.
Elliot then wishes to be a superstar athlete who would be a woman magnet. Satan makes him a seven-foot-plus tall basketball star, but also gives him a small penis and equally low IQ, which causes Alison to lose interest in him.
He then wishes to be intelligent, witty and well-endowed. Satan grants this by making him a famous writer whom Alison falls in love with. When they arrive at Elliot's home to make love it is revealed that Elliot is gay and living with a male partner.
Lastly, Elliot wishes to be President of the United States to try to improve the world. Satan makes him Abraham Lincoln at Ford's Theatre on the night of his assassination.
After each wish is renounced, Elliot meets with Satan and she blames him for not being specific enough. Eventually he returns to work, thinking about what he should do with the last two wishes. Satan appears, pointing out that on their first meeting he asked for a Big Mac and Coke, although she had stated that it was a test wish. Elliot loses his patience and storms out of his office.
Elliot visits a church looking for God's help, where he briefly confesses to a priest who seems sympathetic. However, after being asked whether he thinks asking Satan for a Big Mac and Coke counts as a wish, the priest has Elliot arrested. The sergeant books him, and Satan, dressed as a police officer, throws him in a cell, telling him that she does like him, and it would not hurt to have her as a friend. Elliot's cellmate, (Gabriel Casseus) tells him that he cannot possibly sell his soul as it belongs to God, and although Satan may try to confuse him, in the end he will realise who he truly is, and what his purpose is. Elliot questions the man as to his identity, but the response is simply "a really good friend".
Elliot asks Satan to cancel their contract. When Satan refuses, Elliot states he will not use his final wish. Satan teleports them to Hell, where she transforms first into a black horned monster, then into a giant. When Satan pushes him to make a final wish, Elliot wishes that Alison could have a happy life. Satan sighs and Elliot falls into the depths of Hell. Elliot wakes up on a marble staircase, wondering if it is Heaven. Satan tells him that it is a courthouse and that a selfless wish voids the contract, so he keeps his soul.
Elliot admits that despite her manipulation of him he has come to like Satan and regards her as a friend, something she does not object to. She replies that Heaven and Hell can be found on Earth; it is up to humans to choose. Elliot asks Alison out, only to learn that she is already dating somebody. He continues with his life, but with a better understanding of who he is.
Later Elliot is confronted by Bob, one of his co-workers, who makes fun of his attempts to be cool. Elliot loses his temper and grabs Bob by the shirt, but lets go, simply saying "Nice talking to you." A threatening look sends his other coworkers scurrying.
At home, he meets a new neighbor, Nicole Delarusso, whose looks and personality resemble Alison's and has dressing styles similar to his. He offers to help her unpack and they begin a relationship. While the two walk along a boulevard, Satan and Elliot's cellmate, both dressed in white, are seen playing chess.