Both of these works features betrayal, murder, and an interest in the supernatural. Additionally, each work explores the notion of human evil.
The supernatural appears in Golding's novel in the guise of "the beast". Though this figure turns out to be a specter of the boys' collective imagination, the presence of the supernatural remains an aspect of the text.
In Shakespeare's story, the witches and their prophecies represent a strong supernatural element.
Macbeth has a super-natural dimension to it; indeed, the play opens with the three witches stirring the plot forward.
The plot of each story have some obvious connections with murders taking place in both. Duncan is killed. Piggy is killed. Further betrayals are part of each storyline as well.
These events participate in an exploration of human nature and human evil undertaken by both works.
On the level of human evil, Shakespeare's Scottish tragedy is about Macbeth's bloody rise to power, including the murder of the Scottish king, Duncan, and the guilt-ridden pathology of evil deeds generating still more evil deeds.
Golding's novel considers man in his most native state, a childhood without adult restraint or restriction. In this state, animalistic impulses ultimately prevail. Evil overtakes good.
These are all areas that can be explored in a comparative essay on the two works.