On average, it takes more than 2 months before a new behavior becomes automatic — 66 days to be exact. And how long it takes a new habit to form can vary widely depending on the behavior, the person, and the circumstances. In Lally’s study, it took anywhere from 18 days to 254 days for people to form a new habit.
Second, you don’t have to be perfect. Making a mistake once or twice has no measurable impact on your long-term habits. This is why you should treat failure like a scientist, give yourself permission to make mistakes, and develop strategies for getting back on track quickly.