Putting an extra bit of information in a movie after the credits roll has always been a trick to get people to stay in their seats long enough to see who worked on the film. Bloopers and outtakes are great for kids movies and comedies. Sometimes there's more in or after the credits because test audiences didn’t like the movie's ending, so something more palatable got tacked on, as we saw in Elvis Presley’s first movie Love Me Tender. It’s also a way to set up a possible sequel if ticket sales warrant one. Marvel movies have become famous for doing this, starting with Iron Man in 2008.
After the credits have rolled on the title character (Robert Downey Jr.) defeating Obadiah Stane (Jeff Bridges), Iron Man’s alter ego, Tony Stark, returns home – presumably from a hard day’s work kicking ass – only to unexpectedly be greeted by S.H.I.E.L.D. director Nick Fury, played by Samuel L. Jackson. Luckily for Stark, Fury’s news is good – and it also changes the face of the entire MCU. When Fury dropped the line, “I’m here to talk to you about the Avenger Initiative,” comic book geeks around the world wet their pants in anticipation.
There’s never any doubt that a Marvel superhero movie will have a sequel- they are already planned. However, some twists after the credits roll take away the entire sense of satisfaction of the film’s conclusion. You find examples of all these devices in a list of ten movies with post-credit surprises at Scribol.