Along came a spider...
Aragog is an acromantula, a giant, intelligent spider with the power of speech and a fondness for human flesh- the perfect pet for Hagrid, who raised him from an egg before releasing him in to the Forbidden Forest. Out of respect and gratitude, Aragog refused to attack and eat Hagrid when he came to visit, despite his natural urges. This seems the very least he could do.
However, no such courtesy was extended to Hagrid's friends, as Harry and Ron found out when, with the help of Mr. Weasley's Ford Anglia, they barely escaped the fangs of a hungry and irritable Aragog and family.