Dobby is Harry’s loyal house-elf friend in the Harry Potter book series.
Dobby first appears in Harry Potter and the Chamber of Secrets, where he secretly visits Harry at Privet Drive. He tries to stop Harry from returning to Hogwarts because he knows that the Chamber of Secrets will be opened and that students may be endangered. His warnings are disruptive, but they ultimately come from concern for Harry’s safety.
Dobby originally belongs to the Malfoy family. Harry tricks Lucius Malfoy into giving Dobby clothing, and receiving clothes frees the elf from service. Dobby then chooses to work at Hogwarts for wages, a major change from the unpaid service expected of most house-elves.
Readers sometimes confuse Dobby with Kreacher, the house-elf connected to Sirius Black’s family, or Winky, who serves the Crouch family. Dobby later helps Harry at Shell Cottage and dies after rescuing Harry and his companions from Malfoy Manor.