Happens in WarCraft III, outside the vault where Frostmourne is held:
The Guardian: Turn back, mortals. Death and darkness are all that await you in this forsaken vault. Arthas: I doubt there's anything more terrifying here than what we've faced already. The Guardian: Believe what you will, boy. You Shall Not Pass.
This appears to be nothing more than an invocation of the trope title, until you realize that the scourge may never have become such a serious threat if Arthas hadn't taken up Frostmourne.
Tyrande seems to do this during the events of The Frozen Throne, channeling Starfall standing on a bridge to hold back an advancing wave of undead. Unfortunately, said bridge turns out not to be able to support an elf on top of a tiger in full battle gear, breaking down and taking Tyrande with it (although why did she feel the need to stand on the bridge...). Two chapters later, it turns out the fall didn't kill her, and you have to rescue her from what would otherwise be a last stand on an island in the river.
Inverted in the first Undead mission of Frozen Throne: the remaining humans are all trying to flee their villages into the mountains. You have to prevent them from running off.
Regal's More Expendable Than You moment near the end of Tales of Symphonia was of this type, by standing fast in the face of an army of angels to allow the others to advance without their interference. Unlike most examples, he enters the battle intent on getting out alive, having sworn to Lloyd not to die. He survives.
Asch in Tales of the Abyss pulls this in the final dungeon, as he holds off 4 guards while Luke goes on ahead. To make matters worse, he just gave his sword to Luke, so he has to fight without a weapon at first (he takes one from an enemy mid-fight). Why he didn't ask Luke for his old weapon in return for the Sword of Lorelei is a mystery. In the end, he seemingly kills them, only for 3 to get up suddenly and impale him all at once. He does still manage to kill all of them, but dies of his wounds afterwards.
In the animated adaptation, Luke actually hands him his own sword in return, for all the good that did him.
Literally done by Walter in Tales of Legendia. He shouts "You shall not pass..." and then runs off...
Seems to be a common trope in the Tales series as Judith says it to Nan and Tyson when the show up to try and kill Ba'ul in Tales of Vesperia.
Final Fantasy IV has Cid. After Yang has just made his own (unrelated) Heroic Sacrifice and it seems The Dragon is about to finally kill the rest of the party by demolishing the Tower of Babil's bridge with them on it, Cid catches them on the Enterprise. They are still being chased by other airships, however, and after flying into a tunnel leading to the group's next destination, Cid gives the wheel to Cecil and jumps off the ship carrying explosives. As soon as the ship is clear, Cid detonates his bomb to seal the passage with the enemy still inside (and presumably incinerate/crush himself). However, it was just a Disney Death.
There are two examples in Final Fantasy VI. The first comes when the party is nearly captured by the Big Bad after their raid at a Magitek Factory; even though Locke believes her a traitor, Celes throws herself at the enemy forces and casts a spell that warps them (and herself) to parts unknown, allowing Locke and the others to escape. Much later in the game, as the balance of magic is broken and the world begins to tear itself apart, the mercenary Shadow double-crosses the Big Bad and traps him while the party escapes back to the airship. Although the player is free to leave once the goal is reached (presumably, leading to Shadow's death,) there is also a chance to subvert this trope by waiting for him until the last possible second.
A posthumous example in Final Fantasy VII: Red XIII, who was led to believe that his father Seto was a deserter, discovers his petrified body on the border of Cosmo Canyon. Despite being run through by several magic arrows, Seto kept his footing and maintained an aggressive posture, ensuring that he would defend his city even in death.
In Final Fantasy IX, Steiner, after finally realizing that Queen Brahne has been plotting against Dagger Garnet, offers to stay behind in Castle Alexandria, helping Freya and Beatrix fight the Queen's Black Mages, giving Zidane time to help Garnet escape. Steiner survives, and hooks up with Beatrix.
However, his heroism was later remembered by the villain, when most of his species stand against said villain later and are slaughtered. Only the ones who aren't home and the ones in the Blitzball team survive.
Breath of Fire 2 has a number of secondary characters sacrificing themselves for the party, the party sacrificing itself for the main character, and the main character sacrificing himself for everyone else.
In Super Robot Wars Original Generation, Sanger holds back the UCC forces to give his teammates time to escape... but is actually defecting to the Divine Crusaders' side, because he feels that he can better prepare them for the coming battles as an enemy than as their commander.
Illusion of Gaia featured the protagonists captured by a village where the natives were so desperate for food as to preparing to resort to cannibalism. The princess' pet pig, a faithful companion who has gotten the party out of many tough scrapes by luck and its intelligence, leaps into the cooking fire, sacrificing himself to be food for villagers. Kind of sad...though also somewhat Narm worthy considering the reaction Will has if you examine the cooked remains. Oh, and the fact the pig's name is Hamlet.
In the first Suikoden game, Viktor and Flik pull this one off, earning themselves a No One Could Survive That! Of course, they did survive...they just didn't tell anyone that, for some reason.
Another case in the first Suikoden game was Pahn, a loyal retainer who tries to hold off the imperial army after the hero's army was defeated. You actually get to control him in the duel which determines whether he lives or dies.
In the second Suikoden there was Jowy during the Highland camp infiltration, where he uses holds off the enemy with his True Rune and forces you to run no matter what choice you make. He comes back, but he betrays you shortly after.
In the second NES Ninja Gaiden game, Robert, the CIA agent who is Ryu's ally for most of the game, holds off a horde of demons with a single pistol just long enough for Ryu to make it to the end.
Planescape: Torment does this with all your companions, except for three (one who just pretended to be dead, and depending on your alignment and if you have them with you, as many as two who decide they would rather kill you).
In one of the campaign missions in Age of Mythology, one of the secondary heroes, Chiron, holds off an army of Fire Giants to allow the rest of the characters to escape. He dies, to the great irritation of this editor, because he was a particularly useful unit.
Not only that, but he blocks the passage behind him with a cave in.
Captain Brenner/O'Brian from Advance Wars: Days of Ruin stands fast in the face of the New Rubinelle Army to allow the Independent Legion and the Lazurian Army to escape. He actually manages to eject from his command vehicle and escape, but is nuked to death shortly after.
The combined Lazurian/Brenner's Wolves have another such moment later facing against Tabitha/Larissa's forces in a mountain pass. They're saved by the timely arrival of Will/Ed and reinforcements.
In Grandia II, near the end and while on the moon, the group is surrounded by the young of Valmar, their transport is low on energy and the horde is closing in. Mareg throws the group into the transport and while fighting off massive number makes a prayer (to a) a god he doesn't believe in and b)a god believed to be dead) to send them safety. It works.
In Half-Life 2, Father Grigori diverts the attention of the zombies in Ravenholm, helping Gordon escape to the mines. It is debatable whether he survives or not.
You an clearly see him setting the entrance on fire, killing off the entire zombie horde then running into the catacomb if you wait long enough, which counts as 'surviving' as far as the game tells us. Assuming the explosion of City 17 at the end of Episode 1 didn't take out Ravenholm with it...
In Fate/stay night's Fate scenario, Archer does this towards Berserker to let the heroes escape — the fact that a Command Spell was involved in making him do it is mitigated by the fact that he could probably have managed to save himself in the process if he had stuck strictly to the command wording, which was to 'delay', but chose instead to interpret it as an order to defeat Berserker.
After turning face, Lancer does this on Gilgamesh to let Saber get away with Shirou.
Parodied in Unlimited Blade Works, where Shirou and Rin are faced with Lancer and both attempt to nobly stand in the way so the other one can escape. The realization that both want to give up their life for the other quickly devolves into a lovers' quarrel about which one of them is best suited for the role, both completely ignoring the situation that brought it on in the first place. After a few minutes of standing around watching the two bicker, an extremely amused Lancer reveals that he wasn't there to fight them in the first place.
Exact quote from Aege, the Earth of Foundation, from Soul Calibur III, the Cute BruiserJuggernautDitz with a unique trait that makes her unable to be thrown, knocked down, or stunned. She is the penultimate opponent of Chronicle 11, and cannot be avoided.
Axel pulls this one in Disgaea 2 when he holds off every Overlord in the multiverse who came to kill Zenon so that the heroes could do it. He's doing this both to be helpful and to be a collossal dick of astronomical proportions Dark Hero.
Two in succession at the end of Metal Gear Solid 4. First Meryl stays behind to hold off the FROGS while Snake goes on toward GW, then Raiden does the same. Snake is so awesome that he inspires two "You Shall Not Pass" choke points for the endless swarm of baddies.
Make that three. Lets not forget when Snake fends off the Scarabs in the server room to allow Otacon enough time to upload the virus.
In Lunar: Dragon Song, Rufus sacrifices himself to hold off the giant monster Gideon from being able to chase after the rest of the party. Is killed, with the only thing left to show is his sword, which is later handed over to the Big Bad who gloats about it at the heroes.
Somewhat parodied in Alpha Centauri. Richard Baxton held off four waves of mindworms on his own with a single recon rover, saving a colony. The parody is that his story rights are purchased, then altered and repackaged as "Recon Rover Rick" so that it can be sold as an entertainment franchise, downplaying the horror of his demise.
Subverted in Mass Effect's final battle. As the Citadel closes, the Turian Cruisers attempt this against Sovereign. Sovereign, being Sovereign, just smashes clean through them.
In the sequel, most of your team for the Suicide Mission stays to hold off a horde of Collectors, allowing you and two others to destroy the Collector Base and The Human Reaper. Depending on who is left in that team and who is loyal, none, some, or all of them will get back to the ship and survive. For extra drama/comedy try leaving a single heavy to hold the line.
Shepard invokes this to Harbinger during The Arrival DLC, reminding him that when the Reapers arrive, if they want to take the Galaxy, they will have to face them first.
Urdnot Wrex during the Genophage cure, giving Shepard time to get to the Thresher Hammers: "I am Urdnot Wrex, and this is my planet!" Of course, being the toughest Krogan on Tuchanka, he's back on the radio a bit later shouting at Shepard to hurry up.
In the final part of one mission in Mass Effect 3, Grunt stays behind holding off a horde of huskified Rachni as the party evacuates. It is definitely awesome both for him and for the game designers who set the mood with several important deaths, making it clear that Anyone Can Die, only to pull a Disney Death on the player if Grunt is loyal, and a hilarious one at that. The entire scene is a homage to Serenity, and a similar scene with an engineered Super Soldier who holds off an innumerable horde of monsters.
In StarCraft: Brood War, Fenix and Raynor get one of these in the first chapter. They survive.
In the backstory of BlazBlue, a man called "Bloodedge" fought the Black Beast and held it in check for a year. Though he was eventually devoured by it, Bloodedge's act bought the Six Heroes the time they needed to develop the Ars Magus that would grant humanity victory against the Black Beast. A prequel novel reveals that Bloodedge was the time displaced main character, Ragna. He ended up inheriting his own moniker.
In Halo: Reach, Noble Six does this to let the Pillar of Autumn get away. S/he eventually falls to seven elites.
While not explicitly said, the Six Sages of Team Plasma attempt this under Ghetsis' orders to bar you from your "destined" battle with N. This fails before it gets very far, as Bianca requested backup in advance. The Gym Leaders pretty much do the same to stop them from stopping you, with much more success.
Saga Frontier 2 has this in the one chapter where you control Johan the Assassin. Do note the enemies in that section are actually infinite, and Johan is poisoned to death, meaning you'll eventually lose - but Johan is so strong that you can easily rack up a huge kill count, and in fact, canonically, when people come looking for Gustave and Johan in the wreckage of the area they fought in, they find neither of their bodies among the hundreds of corpses that litter the area. Now you know why you don't mess with Johan.
In Snatcher, Random does this for Gillian when Snatchers have them cornered.
Seen in the final mission of Hello Kitty Roller Rescue, with Kitty stalling an invincible robot until the others can finish it off.
In Ar Tonelico 2 Alfman does this Immediately after his Heel-Face Turn. He blocks the entrance to an elevator against the Divine Army so the main cast can continue their climb.
Happens a lot in the sandbox universe of EVE Online none more famously as the "Siege of C-J6", Red Alliance's homeworld, by the then more powerful Lotke Volterra. The failure of the siege was the beginning of the end for LV.
In Dawn of War: Winter Assault, the Thunderhawk carrying the Titan's crew crashlands Behind Enemy Lines next to a Chaos base. Fortunately, it was escorted by Space Marines, who prevent the Chaos forces from killing the Titan's crew.
In another mission, the Imperial Guard temporarily ally with the Eldar, protecting them until they can teleport their base inside your own. At which point it turns into Hold the Line until reinforcements show up.
Playing as the Orks or Chaos, a large force of Imperial Guard / Eldar / Space Marines is assembled in front of the gate preventing you from reaching the Titan.
Happens near the end of Spec Ops: The Line, as Adams faces off against the last of the Damned 33rd to give Walker time to reach and confront Konrad.
In the intro of Rise of Legends, a lone Vinci warrior, surrounded by dozens of Alin Heartseekers, reaches for a crashed Mini-Mecha and manages to fire its cannon one last time - at the bridge he's standing on and the Heartseekers need to enter the city. A moment later, many of the Heartseekers are seen crashing down.
Gavenger will do this in MS Saga: A New Dawn to hold off the exceptionally humongous Psyco Gundam alone as a noble Heroic Sacrifice. There's a brief Hope Spot when you see a familiar Mobile Suit follow after you as you make your escape, but that hope is cruelly crushed when it's revealed that it's not Gavenger but a replacement character, specifically a former boss who did a Heel-Face Turn, taking Gavenger's suit after his death and following the heroes to help them.
In Kingdom Hearts, Sora, Donald, Goofy, Riku, and Mickey pull one when they close the Door to Darkness, preventing hordes of Heartless from invading the worlds.