Refactor is the practice of altering code to make it cleaner, simpler, and sometimes faster, while not altering functionality. We’ll talk about how to do it better, and discuss: When to refactor. How to refactor. Why refactor. How a refactor can help us write better code in the future. Show a common methodology and steps to follow while refactoring, and resources to help us all on our refactor journey.