I always think of the Grey Goo theory when the subject of nanobots taking over Earth comes up.
"a hypothetical end-of-the-world scenario involving molecular nanotechnology in which out-of-control self-replicating robots consume all matter on Earth while building more of themselves"