First of all, the main recommendation is not to smoke. Ideally, it is best not to start smoking or to quit as soon as possible. However, quitting smoking can be a difficult task, so the help of a doctor can be sought if necessary.
Similarly, it will be necessary to give up alcohol and drugs, since, in addition to other negative effects, they can also affect reproductive capacity.
However, having a balanced diet, exercise, and weight control to have an adequate BMI are good habits that can help improve fertility.