If you see any story in any medium begin with "The Devil and...", it's almost certainly going to involve this trope. The originator of this convention is The Devil and Daniel Webster by Stephen Vincent Benet, the story that first gave us the Jury of the Damned.
For example, a short story titled "The Devil and Simon Flagg" inverts the "ordeal" version by having the title character, a mathematician, challenge the devil to an ordeal: he must either prove or disprove Fermat's Last Theorem. The Devil doesn't make it, despite asking the best mathematicians in the universe. And despite the fact that humans found the solution meanwhile. But he does become fascinated by the problem anyway, and he and Flagg become friends of a sort, discussing possible approaches and theories.
And Benet's story was inspired by an earlier short story called "The Devil and Tom Walker" by Washington Irving. Arguably it was also inspired by Eugene Fields' short story "Daniel and the Devil", wherein it's actually partly inverted as Daniel is a shrewd, though down on his luck (hence the deal), businessman who first cuts out the middleman (Beelzebub) and then persuades the Devil to sign a bond according to which he will get Daniel's soul after fulfilling his wishes for 24 years - and if the Devil breaks the bond, then Daniel is freed of the contract and 1001 souls can freely leave Hell to boot. In addition to this, Daniel is a decent, respectable family man who hardly gives any of the temptations the Devil offers him a thought and instead makes the Devil do all kinds of good deeds, including building a church and ensuring the election of honest politicians. Eventually the Devil can't stand it anymore - the straw that breaks the camel's back is Daniel telling him to close all saloons for Sunday - and is forced to break the bond.
The One Ring of The Lord of the Rings has a will of its own and manipulates the wearer in order to try and get back to its master. This typically involves convincing the wearer that it will grant great power and dominion, just in order to trick the wearer into revealing its whereabouts. Hobbits are resistant to this, most notably Sam, who doesn't want world domination because he can't understand why anyone would want that and has no ambition beyond marrying his sweetheart back home and keeping a garden. In his case it just gave up.
The Robert Bloch Hugo-winning short story "That Hell-Bound Train" is a wonderful example of this trope, complete with a double-twist-ending.
Its title (and the song alluded to in the story) comes from an old and anonymous American folk-song, called "The Hell-Bound Train".
The Larry Niven short story "Convergent Series" deconstructs the Deal With The Devil by not only giving a purported reason why demon-summoning rarely works (and why you wouldn't hear about the successful cases), but also by ruling out each of the usual ways out of the deal one by one. The solution the protagonist chooses is unconventional, but successful: the demon had to re-appear wherever the pentagram he was bound in was drawn. The protagonist chose as his wish to stop time, and then redrew the pentagram on the demon's belly while time was frozen, causing the demon to keep endlessly re-appearing in a fruitless effort to appear inside the pentagram.
Anthony Boucher's story "Nellthu" gleefully plays with this, combined with Three Wishes. "Wealth beyond the dreams of avarice"? NOTHING is beyond the dreams of avarice, so she gets nothing. Perfect health? Sure, for a seventy year old body. But the wisher beats the game by wishing the demon to fall in love with her.
Timm Thaler sells his laughter to baron Lefuet (which is backwards for Teufel, German for devil) in exchange for winning any bet. Later he gets his laughter back - with a bet.
Beautifully deconstructed in Tanith Lee's short story "Sold". A woman with serious medical and financial problems calls on the devil, asking if he would really give her health, wealth, beauty, and long life in exchange for her soul. When he replies in the affirmative, she calls off the deal: all she really wanted was proof that she had a soul and that it was worth something.
Invoked by Don Quixote in chapter XXV of the second volume, in which he and Sancho encounter a magician with a supposed clairvoyant monkey.
Played with in one of the Khaavren books. A young Morrolan agrees to serve the "Demon Goddess" Verra (although demon may not mean the same thing as it usually does) in both this life and the next in exchange for her favoritism. The played-with part is that he does this without a second thought, having no problem at all offering his soul for the future. Granted, this wouldn't mean eternal torment in the afterlife, but rather its implied something more like Valhalla, in which he will form part of an army of champions.
Well, he already is part of an anti-Jenoinegroup of champions. And apparently he's Verra's soulmate as well, so she's probably less inclined to torment him than, say, Vlad.
Darkfriends, especially The Forsaken, from The Wheel of Time sell their Soul to Shai'tan, in exchange for immortality, power and glory if Shai'tan would win. There are at least two problems with this. First Darkfriends are hunted by the good guys and everyone on the bad guys' side has Chronic Backstabbing Disorder, so the odds of any particular bad guy surviving to the end of the series unscathed is very low. And second Shai'tan is said to actually destroy the entire world if he is set free rather than merely conquer it, so Darkfriends are really screwed.
Except for Ishamael, who is not only Genre Savvy enough to know what the Dark One's real goals are, but enough of a Nietzsche Wannabe that he feels the destruction of the universe would be best for all concerned, and joined up with the Shadow in the first place to bring this about. It turns out he was being played for a fool too. The Dark One was not capable, or willing, to grant the destruction of everything, and would have certainly tormented all of his servants forever, not granted them what they wanted. Rand realizes that the Dark One only could show lies.
In Paradise Lost, Satan actually makes a Deal with the Devil (not himself) in order to succeed in his goals when he petitions Chaos to direct him towards Earth by promising that he will cause the world to return to Chaos after he is done. (He lied.)
In Fredric Brown's short story "Naturally", the main character is about to flunk out of college, so he summons a demon to help him pass his Geometry final. But because he's bad at Geometry, he puts the wrong number of points on the pentagram and the demon simply steps out of it and carts him off to Hell. Sometimes Satan has it easy.
In HP Lovecraft's "Dreams in the Witch House", Nyarlathotep appears to the protagonists, offering him complete control over the ability to travel outside the angled space (effectively being able make a personal wormhole between any two locations) in exchange for signing the book of Azathoth with his blood. The protagonist refuses, but judging from what kind of beings we're dealing with, it's probably better not to know what would've happened had he accepted the deal.
Isaac Asimov helped edit two collections of fantasy/science-fiction "short short" stories that included a few examples of this trope:
A villain makes a deal to be reincarnated, and is brought back as his own horrifically-abused daughter. ("Give Her Hell" by Donald Wollheim.)
A man makes a deal with what he thinks is a devil. ("Your Soul Comes C.O.D." by Mack Reynolds)
A story which squeezes into five pages every conceivable pun based on the phrase "pact with the devil." ("If At First You Don't Succeed, To Hell With It!" by Charles Fritch) This was written when the editors of Fantasy And Science Fiction told Fritch that they were not running any more stories on this "overworked" theme. He set out to write a deal with the Devil story they would have to run, about a writer who sells himself to the Devil, and can only escape by getting his story published in a magazine...
A poet comes to not regret selling his soul for wealth and fame, but the rest of civilized society does... ("The Devil Finds Work" by Reynolds again.)
Asimov himself wrote a story where a man sells his soul for the rather wholesome payoff of ten years of wedded bliss with the girl he has a crush on. His is a slightly unusual deal, because at the end of the ten years he will be temporarily be given the powers of a demon and placed in a trap. If he can't escape, he will be damned for eternity; if he can escape he will become a demon for all eternity (Hell needs new ideas, and who is more evil and demonic than humankind? So at the end of his life he wakes up in a room with solid bronze walls on every side and has to escape which he does by realizing that the room is not solid in the dimension of Time and demons can travel in time, so he goes back to the moment when he signs the contract with the demon and rips it up. And wins the girl anyway.
Subverted in the Ogden Nash poem "The Miraculous Countdown", a story about Dr. Faustus Foster, described in the poem as "a truly incompetent scientist", who in desperation after all of his efforts at a major scientific breakthrough failed spectacularly, swore that he would sell his soul to succeed. A red-robed figure popped in and made him a deal for his soul. Once accepted, Dr. Foster became a heralded and respected scientist whose discoveries were put to use for the good of mankind. The switch comes in the final stanzas;
Faustus, clumsiest of men, Had butterfingered the job again. I told you his head was far from level, He thought he had sold his soul to the devil When he really sold it, for Heaven's sake, To his guardian angel by mistake! When geniuses of every nation Hasten us towards obliteration Perhaps it will take the dolts and the geese To drag us backwards into peace.
In the Chronicles of the Kencyrath, Gerridon made a deal with Perimal Darkling in the Backstory that involved his getting immortality for the price of destroying two-thirds of his own people and devouring their souls, which he gladly fulfills. Fast-forward three thousand years, however, and Gerridon finds himself in a bit of a bind, as he's running out of harvested souls to feed on- when that happens, old age will catch up to him and kill him. He's been offered a revised Deal, which would involve surrendering his own soul to Perimal Darkling and getting true immortality as its avatar, but as of yet has not accepted, preferring to find someone to reap more souls for him- namely, Jame, his niece.
In Vale of the Vole, Esk watches a play about a man who summons a demon and makes a contract with it to obtain wealth, women, etc... but the contract contained a phrase that read "The demon will not attempt to harm the person signing the contract", and a drop of wax just happened to fall so that the word "not" was obscured...
In "The Bottle Imp" by Robert Louis Stevenson, the eponymous bottled imp can grant as many wishes as is desired, but if you possess it at your time of death, you lose your soul. In order to get rid of it, it must be sold at a loss to you.The main character's wife buys the bottle from him, for next to nothing, and manages to sell it at a tiny loss to a drunken old sailor who's quite sure he's bound for Hell anyway and wants the imp to provide him with liquor for the rest of his days.
Ivan Krylov has a fable about a purse you can also draw coins from... the catch being, you cannot spend a single one until you get rid of the purse. Cue Death by Materialism.
In the Fredric Brown story "Nasty" the protagonist makes a deal with the Devil for a pair of magic swimming trunks to restore his virility. But if he takes them off or even pulls them down....
In Brian Jacques' book Seven Strange and Ghostly Tales, the story "The Lies of Henry Mawdsley" is about a ten-year-old boy who sells his soul in order to become the world's most believable liar for one week so he can get out of schoolwork. When "nice Mister Nick Lucifer" tries to claim his soul at the end of the week, Henry is saved by the Archangel Gabriel, who demonstrates that Henry is an undiagnosed dyslexic, therefore the contract is not valid because Henry lied about being able to read and understand it.
The character Sinner in the Nightside book Hex and the City sold his soul for true love. Upon his death, he was told that his "true love" was actually a demonic succubus by the name of Pretty Poison, who had been roped into the job by Satan and spent ten years pretending to love him. Sinner didn't care, as from his point of view he was truly in love, and his refusal to give up resulted in Satan kicking him out of Hell because he was ruining the atmosphere. Pretty Poison got curious and followed him up, and eventually got her angelic status back by sacrificing herself to save him - demons in the Nightside universe, if killed on Earth, lose all their power and become regular damned souls.
In the novel Ascending of The League of Peoples Verse, Oar is offered a deal by a Sufficiently Advanced Alien called the Pollisand, who pulls out all the stops in presenting it as a Deal With The Devil scenario, complete with fire, brimstone, classical allusions, the works. Subverted; Oar takes the deal and the Pollisand gives her exactly what he promised, with no apparent negative consequences whatsoever.
In I, Lucifer the titular character mentions that the actual contracts are symbolic and that the act of signing them is all that matters. It's worth noting if you're not specific on the means of which Lucifer has to go about completing his end of the deal, he will screw your dumbass over.
In The Guardians, demonic bargains can be cancelled by either party before one side is filled. After that, if the other party doesn't fulfill their side, they are damned to the field of frozen faces. Demons don't bargain for literal souls, although they often ask for something that will drive the human to damnation such as betraying a friend or murdering an innocent.
Harry has been offered a few of these in The Dresden Files, in a couple cases by actual Fallen Angels. In Changes, he decides to take one, and chooses Mab, Queen of Air and Darkness as the least evil option. Though probably more evil, Lasciel would at least have an exit strategy - he personally knows someone who accepted a similar deal and gave it up without harm. While the only way he sees out of being the Winter Knight is a prolonged, painful death. Harry already had an exit plan that involved taking out a hit on himself and having his apprentice erase the memory of said hit. That being said, Mab was still a safer choice than Lasciel as Mab is not an inherently evil being, whereas the Denarians are. Mab is more of a callously neutral force whose purpose - which Harry learns later - isn't to hurt or malign humans. Though she enjoys it.
Averted in The Lesser Key of Solomon. The conjurer uses the fact that they are human (thus made in the image of God and under his protection) to get the demons to do what they want, rather than trade their soul.
In Faction Paradox stories, there is a rather odd group of Energy Beings called the Celestis. They appear to be gods and demons of myth, and live in a fortress of pure meaning called Mictlan. They are not actually gods or demons. They are Homeworld agents who have undergone a process that transforms their physical bodies into Memetic Mutations, making them indestructible but dependent upon mortals continually thinking about said memes so they won't drift into oblivion. They work rather simply: they visit low-level planets where people are less likely to come up with some ingenious stratagem to overcome them, and there they will offer their services: they will grant you your heart's desire, with certain limitations (no godhood for ya, sorry) and upon death they have complete rights to seize your soul, drag it to Mictlan's dungeons, and set it into their wonderful machines so you have absolutely no choice but to continually think of the Celestis, until the End of Time itself. Have fun.
They tell how the first queen of our line had traffic with a fiend of darkness and bore him a daughter who lives in foul legendry to this day. And thereafter in each century a girl baby was born into the Askhaurian dynasty, with a scarlet half-moon between her breasts, that signified her destiny.
Played straight by Stephen King's novel Needful Things where everyone is offered the one item they want most in return for a small favor. Of course all those mostly harmless little pranks lead to the town pretty much tearing themselves apart and theres very little doubt whats in that bag the shopkeeper attempts to leave with. Bonus points could probably be given for the fact that these things are only seen or felt as the real thing by the maker of the specific pact and to everyone else are just random bits of garbage.
Defied in The Screwtape Letters, which is about the workings and tactics of demons. Screwtape mentions that Hell's official policy now frowns on Faustian bargains, as they confirm the existence of the supernatural and thus undermine Hell's atheism campaign.
In the Left Behind series, the signing of the covenant that would allow the Global Community seven years of licensed use of Chaim Rosenzweig's synthetic fertilizer formula for Israel's peace with other nations was seen as the very thing that starts the seven-year Tribulation period.
Peter Schlemiel in the eponymous story by Adelbert von Chamisso sells his shadow to a mysterious man in a gray coat in exchange for a magic purse that supplies endless amounts of gold pieces. The shadowless protagonist becomes a social outcast, despite spreading extravagant amounts of money around; his love interest rejects him when she discovers his secret. Exactly one year after the original deal, as promised, the man in the gray coat returns with an offer to sell Peter him back his shadow and restore his good name so he can save his love interest from marrying his wealthy but no-good rival, on the condition that he merely supply his signature on a document written in his own blood. He stubbornly refuses to bargain away his soul, and ultimately banishes the devil by throwing away the purse.
Special Circumstances: Not the Devil, but David Krake does make a deal with a demon for the purpose of becoming a famous bestselling author.
The Hound Of The Baskervilles has as a backstory the legend of a man who promised his soul to the devil if only he'll catch the girl who escaped his clutches. As soon as he does catch up with the girl (dead from exhaustion), he is killed by a demon - the titular hound.
In "By These Presents", by Henry Kuttner, a man sells his soul to the devil in exchange for immortality and invulnerability unless he commits suicide. The devil, however, takes as security a part of his soul - some part of the subconscious. The man, however, fails to achieve happiness, decides it's the taken part which prevents it, and demands the devil return it. The devil does. The catch is, the part taken was the man's conscience, and the return was followed by a gun to the temple some ten seconds after it was reintegrated.
Chichikov from Dead Souls definitely invokes this with the whole "buying people's 'souls'" thing and he's a lot like the "devil as small time bureaucrat"/The Devil Is a Loser portrayal in works like "The Devil and Daniel Webster" and The Brothers Karamazov (both post-date this novel, but probably draw from the same idea). In fact, both Chichikov and Scratch store their souls in a box- the only difference is that Chichikov's are metaphorical.
The miller in Krabat did one. As a price, he has to sacrifice one of his students/apprentices each year - or will lose his soul himself. And sometimes at night, the boys will have to do an extra shift - as Krabat finds out, to grind bones and teeth, presumably human ones.
Such a deal is discussed in "The Cambist and Lord Iron". It's worth mentioning that the deal is essentially the reverse of the traditional one. Lord Iron isn't looking to sell his soul; he's looking to buy it back.
In the short story "The Smoking Room" by Shirley Jackson, the Devil appears to a wily college girl and her roommate. After discovering that the Devil Never Learned to Read, the girls quickly draw up a contract they insist is more legally binding, convince the Devil to give them several million dollars and passing grades in calculus, then have him sign it. Only then they reveal that, amid the legalese, the contract actually states that the Devil has agreed to grant their wishes and give them his soul—for a dollar.
In the same collection, another story, "Devil Of a Tale," sets the same theme in medieval times, with a much darker outcome.
Devilish has a character that makes a deal with the Devil, or rather, one of his minions.
The main character of the novel Crawling Chaos Blues is a failing blues musician who resorts to trying to make the same deal as the above mentioned Robert Johnson, only instead of the devil, he makes a deal with someone that's arguably worse (the title gives it away).
In Teresa Frohock's Miserere: An Autumn Tale, Catarina made one for her own soul's, and her brother's. She was less able to deliver than she had thought.
Towards the end of The Monk when Ambrosio finds himself in way over his head, Matilda tells him if he will give his soul to Satan, he can be saved from the angry mob. Ambrosio accepts.
In Dark Future novel Comeback Tour, the version of Elvis that appears as a protagonist is revealed to have previously come close to this, due to his manager being funded / controlled by the series Big Bad, Elder Seth.
In Robert Westall's Futuretrack Five the Glaswegian gangster, Blocky, is very heavily implied to have done just this; having come to the point of suicide and then being mysteriously inspired to paint a weird and loathsome painting after seeing a demonic face appear in the mirror. Everything's gone just fine for him thereafter.
Wyrm, the main villain of The Book of the Dun Cow, preys on the old rooster Senex's insecurities and desire for respect to tempt him into fathering Wyrm's son, who turns out to be an Eldritch Abomination which doesn't hesitate to kill its host parent.
Flyte:Simon Heap with DomDaniel about the ExtraOrdinary Apprenticeship.
Queste: Merrin Meredith with Tertius Fume about a Thing and sending Septimus onto the Queste.
Syren: Joe Grub, later Theodophilus Fortitude Fry, with Tertius Fume about gold.
In A Bad Spell in Yurt, newly-arrived Royal Wizard Daimbert spends most of the book trying to figure out what the evil influence in the castle is, and eventually works out that it's a demon who made a deal with a not-very-bright noble lady: her soul for the appearance of youth. Daimbert eventually manages to get her off the hook through a Heroic Sacrifice that only a literal miracle saves him from.
In a later book in the series, Daimbert's young daughter negotiates with a demon summoned by another, not realizing the seriousness of her actions. Fortunately for her, the man who summoned it chooses to offer up his soul immediately in exchange for the demon relinquishing his claim on her.
Subverted in China Miéville's Perdido Street Station, in which the leaders of the city of New Crobuzon are so desperate to rid themselves of a particularly nasty breed of monsters that they plead with Hell itself for assistance... and Hell refuses. Out of fear.
In John Dickson Carr's The Devil in Velvet, the book opens with the protagonist selling his soul to the Devil to travel back in time. The Devil keeps up his end of the bargain, but (of course) has a few jokers of his own to play.
Legacy of the Dragokin: Mordak makes Kalak the following deal: give me control of your body and you will live long enough to see your son again.
In the Honor Harrington series, it's mentioned that State Sec analysts half suggest the titular heroine has been in position to ruin the People's Republic of Haven plans by pure coincidence, while the other half suggest this trope as an explanation for her so regularly winding up in just the right place to cause the PRH problems.
In Brimstone Angels, the heroine Farideh kicks off the plot when she makes a Deal with the Devil, specifically, a devil named Lorcan in order to acquire magical powers note Since this is a Dungeons and Dragons setting, see the entry under Tabletop Games for further details about what being a warlock entails. Lorcan himself turns out to be a fairly decent fellow, by devil standards (meaning that he's manipulative, controlling, obsessive, and borderline-sociopathic, but he's not needlessly sadistic and is actually somewhat fond of Farideh)- the real problem is that plenty of other devils, including Lorcan's much more frightening relatives, would be more than happy to poach her from him, seeing as she actually turns out to be a member of a bloodline with ties to Asmodeus himself, making her quite the coveted prize in hell indeed.
Thomas Mann's son Klaus Mann wrote a similar novel, Mephisto, about a German actor who sells out his principles to gain favor with the Nazi Party. The protagonist is a thinly veiled Gustaf Grundgens, Mann's brother-in-law.
In The Count of Monte Cristo Dantes, in character as The Count of Monte Cristo tells an enemy (de Villefort) that he made a deal with the devil, sacrificing his soul for the chance to become a divine agent of providence. The exact nature of this story is left ambiguous. It is possible that Dantes' damaged mind genuinely thought that he made a deal with Satan, but it's more likely that Dantes was messing with de Villefort.
In Coda, After his capture, Anthem is given the best musical equipment the Corp has... to produce tracks that will control everyone.
In Pinocchio, the title hero, along with Lampwick and a group of other bad boys in effect sell their souls to the Little Coachman in exchange for a time of unlicensed pleasure at Toyland, only to end up being cursed into becoming donkeys to slave away for their rest of their short and unhappy lives.
In Pact, gaining supernatural power almost always requires dealing with some supernatural creature, or Other. The bargains can range from agreeing to keep the bound form of a ghost in a place of warmth, to agreeing to fight monsters for the rest of your life, to giving up the ability to swear, and the Others that give powers are similarly varied. The actual devils in the setting, notably, tend to keep their word fairly well if the practitioner that bargains with them is careful enough not to give them an opening, so while all power comes with a price, it doesn't always have to be you that pays it.
Trademaster is the "Devil" in Messenger who offers steep prices for the selfish desires of the villagers. For example, it's implied Ramon's mother traded away her children's health for something as insipid as a Gaming Machine, while Mentor trades away his "true self" in order to become young and handsome (and a jerk) in order to romance Stocktender's widow.
The Rogue King has a rather tame version of trading his shadow for wings.
In the Daniel Faust series, Demons of the Venerable Order of Bargainers turn this into an art form, and are basically Hell's rock stars. As far as Daniel himself goes, several demons poke fun at his surname and explain that they wouldn't trade for his soul even if he wanted to: he's spoiled goods.
Mrs. H, the wicked stepmother in Six-Gun Snow White, is implied to have made some kind of deal with dark powers in order to escape her own childhood abuse.