CBS

One of America’s most beloved TV shows in recent years, CSI: Crime Scene Investigation, ended its 15-year run on Sunday night with a feature-length special, ironically titled “Immortality.” CSI quickly became America’s most-watched show when it debuted in 2000, but like so many former hits, it faded out after years of declining ratings and multiple attempts to reboot its cast. The finale got a respectable 12 million viewers, but was beaten by ABC’s new show Quantico, and barely matched its final season’s average viewership.

The finale special mostly functioned as a piece of fan service—the most a network can do for a show that once served as its flagship product. The episode brought back all of CSI’s original characters and had the central pair Gil Grissom (William Petersen) and Sara Sidle (Jorja Fox) resolving a long-dangling romantic subplot that was all but abandoned years ago when the actors moved on.

It also served as cross-promotion for the show’s one remaining spinoff, CSI: Cyber, with Ted Danson’s character joining the Cyber team after five years manning the ship on CSI. Danson’s presence underlined the central paradox of maintaining such a long-running show: As CSI stayed on the air, its actors became more and more expensive, but when the original cast left, CBS needed new stars to draw new viewers. Laurence Fishburne was the first replacement, then Danson, but they couldn’t stop a ratings slide (the show averaged 26 million viewers in 2005, 15 million in 2010, and 11.5 million in 2015). In the end, those steadily sagging ratings couldn’t justify rising costs.

It’s a decline experienced by many a former hit show. Before CBS even had CSI, NBC’s Law & Order was an Emmy-winning ratings bedrock for the network that spawned many a spinoff and ran for decades. Even as critical attention disappeared and new actors began cycling through the show, it clung on with decent ratings mostly due to name recognition, and then sputtered out with little fanfare (its series finale was a drama-light whodunit like any other). CSI’s spinoffs had a similar life cycle: CSI: Miami was almost as big a winner as the original show but petered out in 2012 after 10 seasons, and CSI: New York followed in 2013, after nine.

ER lost the entirety of its original cast over 15 seasons and only saw ratings boosts when old favorites like George Clooney or Anthony Edwards popped back in for a special episode. The X-Files creator Chris Carter dreamed of carrying his show on for another 10 years with new actors after David Duchovny and Gillian Anderson left, but an abortive attempt at that formula saw ratings crater and a finale quickly followed. (Lo and behold, Fox has decided to revive the show with the original cast next year.)

Some shows, for better or worse, go out roughly on top. Friends was still hugely popular when it finished after 10 years (spoiler: Rachel gets off the plane), but NBC knew its cast was too expensive to keep on the air forever, no matter the numbers. Seinfeld went out as America’s most popular show, with its creator declining millions of dollars to keep it running, but its maligned finale probably reflected a coming critical downturn that Jerry Seinfeld wisely sought to avoid. The last episode of M*A*S*H remains the most-watched non-sports broadcast in TV history, but even that show, having run longer than the Korean War, knew its time was up.

There’s the rare hit that ends on its own terms rather than at network insistence—Lost creators Damon Lindelof and Carlton Cuse famously drew a line in the sand over scheduling an end date. Breaking Bad and Mad Men were two hits on AMC that followed that example, with their creators understanding the value of not outstaying their welcome. But eventually, no matter how big a phenomenon a show is, economics become a concern. HBO’s Game of Thrones is, ratings-wise, the network’s biggest success in years, but it has the advantage of a cast that’s locked into a seven-season deal. Once those seven seasons transpire, keeping that huge ensemble onscreen will be costly and hard to justify. Ensemble sitcoms like The Big Bang Theory and Modern Family might be big earners for their networks, but like any show, their ratings have started to flatten out, while their production costs have only risen: the same equation that sunk CSI.  Every show, no matter how popular, has an end date—the only real question is how many people will care when it eventually rolls around.

We want to hear what you think about this article. Submit a letter to the editor or write to letters@theatlantic.com.