Neville Longbottom killed Nagini with the Sword of Gryffindor during the Battle of Hogwarts. After Harry appeared to be dead, Neville stood up to Voldemort and pulled the sword from the Sorting Hat, then beheaded the snake, destroying the final Horcrux. This moment fulfilled the prophecy that Neville would also have a role to play in Voldemort's defeat.