rule of thumb would be the sooner the cheaper, but how many weeks or months in advance?
For my particular flight there are only three companies and it seems flights are cheaper between Tuesdays and Thursdays. However, if you want to book a flight 2 months from now, it’s considerably cheaper.
Have you found the sweet spot?
depends on many variables so there can never be a simple rule. Airlines want their planes full of paying customers is the real rule. They change prices based on how full each plane is. Sometimes a nearby city can be orth heading to for a much better deal.
And some airports are cheaper than others. My last international flight was 2x the cost to fly out of Houston (IAH) vs out of Austin. Even for the flight that went from Austin to Houston and then to the destination.