Overfitting or curve-fitting is optimization done incorrectly, carelessly, or gone wrong in some other way. This chapter puts forth the proposition that the overfitting of a trading strategy to historical data occurs when testing and optimization are done incorrectly. The effects of the overfitting or curve-fitting can lead to significant and immediate real-time trading losses. To help the strategist avoid overfitting, this chapter identifies the symptoms that result from the accidental abuse of proper testing and optimization methods. This chapter also includes an extensive discussion of a variety of methods designed to detect and avoid curve-fitting, including the most effective way to do this, which is to include out-of-sample testing in the optimization process. The chapter highlights the cases of the overfit forecasting model and overfit trading model; the symptoms of an overfit trading model; and causes of overfitting.