Three-pile ending
A three-pile ending is when the game ends by emptying three piles, rather than the Province (or Colony) pile. When this is done as an intentional, strategic move by a player, it is called three-piling.
A few cards, usually Alt-VP cards in rush games, play best when a three-pile ending is the goal, and there are many cards, including +Buy, gainers, and cursers, that can be very useful in achieving such an ending.
In games with more than four players, four empty piles are required to end the game, but most competitive Dominion play is done with only two players.
Cards that like three-pile endings
Most counting Alt-VP cards:
Victory token cards that need to continue adding cards for fuel:
Swift-acting cursers:
Strategy
In order to achieve victory with a three-pile ending, you have to be sure that you have the most . The most straightforward way to do that is by cheaply increasing your own points with Kingdom cards. Alt-VP cards that give static , like Harem and Island, are usually not enough to justify trying to empty out three piles, though Distant Lands' 4 is often quite tempting. The counting Victory cards, like Gardens, are more likely to provide enough to to viably compete with Provinces, but most need some sort of gaining enabler, like Workshop or Ironworks. Bishop usually needs help trashing to merit three-piling, but in such Kingdoms it might be more worth it to go for a golden deck and just buy Provinces; Goons, on the other hand, usually needs the help of an engine so it can be played consistently, and in multiples, in order to produce enough to overwhelm any player foolish enough to only go for Provinces. Ill-Gotten Gains is the ultimate three-piler, as it provides both the (in this case simply relative to your opponents due to all the Curses they've been given) and the pile emptying; once all the Ill-Gotten Gains are gone (barring any Ambassador or Trader shenanigans), two piles are empty, and the Ill-Gotten Gains player just needs to empty a third, usually the Estates or Duchies.