Losing weight

Hi everyone. So I’m trying to lose weight to get because I would like to be a healthier weight before I get pregnant. I currently weigh 250 and want to lose at least 50 pounds. I would like to have a baby within the next year. I know that I need to diet and exercise but my issue is staying motivated. I can do it for a while but then I lose all control and and motivation. Any tips or tricks on how I could stay motivated??