When to tell your roommate and closest friends you are transferring?

Waiting to say something is just going to make it worse. Kids are making plans now for housing next year. Many college students choose next year’s housing even earlier. Frankly, it would have been best to mention the transfer option at the start. You didn’t though, so just say “hey guys, you’re all great, but I was offered a guaranteed transfer to X college and I’m taking it.” They aren’t suddenly going to dislike you for being honest.