You've got 3 options really:
- Piccadilly line (tube / underground) the whole way, 45 minutes roughly every 5 minutes
- Heathrow Express to Paddington (15 minutes every 15), then circle line round to Gloucester Road (10 minutes plus changing and waiting)
- Elizabeth Line to Paddington (25 minutes every 15), then circle line round to Gloucester Road (10 minutes plus changing and waiting)
Heathrow Express is very expensive on the day, but you can get decent pricing buying a ticket in advance. Elizabeth Line costs more than Piccadilly, but you'll hit your daily cap for oyster / contactless straight away with it
If it were me, I'd take the simple no change option and hop on the tube