Image copyright AP Image caption The first full series of The Simpsons was broadcast in 1989

The 600th episode of The Simpsons has been broadcast, making it one of only two scripted primetime shows in the US to reach the milestone.

The other, Gunsmoke, ran for 20 seasons from 1955 to 1975 and holds the record for the most episodes, with 635.

The Simpsons, which began as a series of shorts in 1987, has more seasons to its name, but has fewer total episodes.

The animated comedy broadcast a Halloween special, Treehouse of Horror XXVI, to mark its 600th show.

The Treehouse of Horror instalments have become a staple of The Simpsons, airing every October and often featuring parodies of thriller and horror films.

Sunday evening's episode included parodies of The Hunger Games and the Colin Firth film Kingsman.

Assuming The Simpsons is renewed for another season, it will overtake Western drama Gunsmoke sometime in 2018, when episode 16 of season 29 airs.

The Simpsons started life as part of The Tracey Ullman show.

After proving popular with viewers, the cartoon was commissioned for a series of its own, which began airing in December 1989.

The show recently overtook Lassie, which aired 591 episodes, to become second longest-running scripted primetime series behind Gunsmoke.

Earlier this year, it was announced the first hour-long episode of The Simpsons would be broadcast in 2017.

Follow us on Twitter @BBCNewsEnts, on Instagram, or if you have a story suggestion email entertainment.news@bbc.co.uk.