https://flightaware.com/live/flight/UAL5799
Gates are going to be pretty random.
5799 has been used as the flight number for DTW->ORD for the past week or so. Looks like half the time it has arrived in B (Terminal 1)....half the time it arrived in E(Terminal 2)
Your flight to CA will be mainline, so will be in Terminal 1...either B or C gates.