Measure and crush the chocolate cookies or graham crackers until they resemble dirt, then set aside.
If using instant pudding, whisk the pudding mix with milk until fully combined and thickened, then chill in the fridge for at least 15 minutes.
Add the chilled vanilla pudding and the prepared mixture to a large mixing bowl.
In a separate bowl, beat the heavy whipping cream with sugar until soft peaks form, producing a fluffy texture and light aroma.
Gently fold the whipped cream into the pudding mixture, combining until smooth and airy.
Layer half of the cookie crumbs at the bottom of your serving dish, creating a crumbly, dirt-like base.
Spoon the creamy pudding mixture over the cookie layer, smoothing the top gently with a spatula.
Add the remaining cookie crumbs on top of the pudding layer to resemble freshly turned dirt.
Just before serving, nestle gummy worms into the top layer, allowing some to peek out for a fun, messy look.
Chill the assembled cake for at least 30 minutes to let the layers set and flavors meld.
Serve the Dirt Cake with gummy worms wriggling out, ready for a playful, spooky Halloween treat.