J.R.R. Tolkien gives the great spider in Cirith Ungol the name Shelob. She appears in The Two Towers, where Frodo and Samwise encounter her while traveling toward Mordor.
Shelob dwells in a tunnel near the pass of Cirith Ungol. She attacks Frodo after Gollum leads the hobbits into her lair, and she poisons him with her sting. Sam then uses Sting and the Phial of Galadriel to drive her away, believing Frodo dead until he discovers that Orcs have taken Frodo’s body.
Shelob is descended from Ungoliant, a far older and more powerful spider-like being from Tolkien’s First Age mythology. The two names are therefore related but not interchangeable. Shelob is also not a giant spider from another fantasy franchise; her role is specific to the journey through Mordor in The Lord of the Rings.