As a mid-seniority developer, I'm just now starting to grasp the harsh reality of a full refactor. We always think we can improve the speed and code of a website but, man, that's really though.
I always remember the "let's throw away Windows ME codebase for NT" scenario. Sometimes giving up is better I suppose.