Deus ex Machina in Film & Literature. Definition & Examples.


Definition: Deus ex Machina is a literary device where an unexpected power or event saves a seemingly hopeless situation, often feeling contrived. In film, it’s used to abruptly resolve complex or dire situations, typically introducing a sudden character, ability, or object, surprising the audience, and moving the plot toward resolution.

In modern storytelling like film, “deus ex machina” is often used critically to describe a contrived plot resolution that feels sudden or unearned.

It can be seen as a sign of weak plotting when an author relies on such a device to solve a story’s conflicts without adequately setting up the resolution within its logic and context.

Examples of Deus ex Machina in Movies

Below are four examples of deus ex machina events in movies.

These examples show how deus ex machina provides dramatic resolutions, often stirring debate among audiences and critics about the appropriateness and creativity of such solutions.

War of the Worlds (2005)

In this Steven Spielberg film, the Earth is invaded by a seemingly invincible alien force.

Humanity appears doomed, but suddenly, the aliens start dying off because they cannot cope with Earth’s bacteria.

The resolution comes from an unexpected and barely foreshadowed external force, qualifying as a deus ex machina.

The Eagles in The Hobbit: An Unexpected Journey (2012)

The eagles often appear at the right moment to save the characters from seemingly inescapable danger.

Their timely interventions, especially in “The Hobbit: An Unexpected Journey,” where they rescue Thorin’s company from orcs and wargs, can be considered a form of deus ex machina.

Independence Day (1996)

The sudden discovery that a computer virus can be used to disable the alien shields serves as a deus ex machine.

This allows the protagonists to launch a successful counterattack against the alien invaders, resolving the central conflict in a somewhat contrived and overly convenient way.

See the best movie quotes from Independence Day.

Interstellar (2014)

Near the climax, Cooper (Matthew McConaughey) finds himself in a multidimensional space where time behaves differently, allowing him to communicate with his daughter in the past and provide her with the data needed to save humanity.

Some viewers interpret this as a deus ex machina because it provides a sudden and unexpected solution to the film’s looming disaster.

Deus ex Machine: Origin and Meaning

“Deus ex machina” is a Latin term that translates to “god from the machine.” It originally referred to a plot device in ancient Greek and Roman drama.

In these plays, a god would often be lowered onto the stage by a crane (the “machine”) to resolve a seemingly unsolvable problem or to save the hero or heroine from a dire situation.

Over time, the term has evolved to refer more broadly to any unexpected, artificial, or improbable character, device, or event introduced suddenly in a story to resolve a situation or untangle a plot.

Examples of Deus ex Machina in Literature

Here are examples from literature where Deus ex Machina has been employed:

“Medea” by Euripides

In this ancient Greek tragedy, the title character, Medea, is provided a chariot by the sun god Helios, which she uses to escape after committing her crimes.

This divine intervention helps her avoid the consequences of her actions, unexpectedly resolving the play’s conflict.

“Lord of the Flies” by William Golding

At the novel’s (and movie’s) climax, when the other boys are hunting down Ralph, a naval officer unexpectedly arrives on the island, rescues them, and ends their ordeal.

This sudden rescue can be interpreted as a Deus ex Machina, ending the boys’ savage descent into chaos.

“Harry Potter and the Chamber of Secrets” by J.K. Rowling

At the book’s (and movie’s) climax, Harry Potter is in the Chamber of Secrets without any hope of defeating the Basilisk or Tom Riddle’s memory.

However, Dumbledore’s phoenix, Fawkes, arrives unexpectedly with the Sorting Hat, providing the sword to Gryffindor. This intervention allows Harry to defeat the Basilisk and save Ginny Weasley, serving as a Deus ex-Machina.


The use of Deus ex Machina in literature and movies is a pivotal narrative device, enabling storytellers to resolve seemingly insurmountable conflicts or plot points with an unexpected, often divine intervention.

While it can offer satisfying conclusions or dramatic twists, its use requires careful handling to avoid undermining the story’s credibility or character development.

When executed skillfully, it enriches narratives, leaving audiences in awe and contemplation of the extraordinary.

Up Next: What is Consonance in Film, Literature, and Music?


  • Jan Sørup

    Jan Sørup is a indie filmmaker, videographer and photographer from Denmark. He owns and the Danish company Apertura, which produces video content for big companies in Denmark and Scandinavia. Jan has a background in music, has drawn webcomics, and is a former lecturer at the University of Copenhagen.

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.