This is obviously project-specific, but most rewrites that I've been a part of are usually not "re-implement everything from scratch", but rather "re-implement everything based on this new framework/library", which will usually be one more layer of software, on top of the few things to be salvaged from the original.
Small projects can be re-written; big projects like browsers, compilers, OSs require too much investment.
Small projects can be re-written; big projects like browsers, compilers, OSs require too much investment.