Phentermine is used together with diet and exercise to treat obesity, especially in people with risk factors such as high blood pressure, high cholesterol, or diabetes.