Refactoring is a process of cleaning up, tidying up, and improving code without affecting its functionality. The process is done incrementally rather than all at once.
Refactoring is the process of restructuring existing code, modifying its internal structure without affecting its external behavior. At its core, it is a series of minor behavior-preserving adjustments. Each adjustment (called also a "refactoring") does minimal change, but a succession of these adjustments can cause a significant reorganization. Refactorings are less likely to go wrong because they're small. By keeping the system fully operational after refactorings, the possibility of a system being seriously damaged during restructuring is considerably reduced.