The only way from Denver to Boulder is by public transit. You should expect to be able to find tickets starting around $11, if you search flights from Union Station to Boulder Transit Center. Take public transit from Denver to Boulder, it's your best chance!
The earlier you can book your trip to Boulder, the better. There is usually no need to book these sort of trips from Denver to Boulder in advance. Rideshares should be available on demand all hours of the day. Public transportation prices do not fluctuate like flights. Instead, they're either flat rate or priced by distance traveled. If possible, you can book your tickets via an app or alternatively at the station upon arrival.