Spite implies intent.
As an outside observer spitefulness and stupidity may appear the same, but the stupid person may have had good intentions and no ill-will towards those they harm.