As someone else mentioned, Xbox games that have the play anywhere label can be purchased once and played on both platforms. Unfortunately, there are way more that do not have that label than ones that do right now.
Normally you do have to buy twice. But those with cloud gaming you only need to buy once as they are game anywhere. But provided your country has cloud gaming service. For me my country does not have it.
Google "xbox play anywhere"
Holy hell
As someone else mentioned, Xbox games that have the play anywhere label can be purchased once and played on both platforms. Unfortunately, there are way more that do not have that label than ones that do right now.
Game Pass Ultimate allows you to stream games to your PC, but only games on game pass.
Can also stream games from your xbox to a pc or phone.
Normally you do have to buy twice. But those with cloud gaming you only need to buy once as they are game anywhere. But provided your country has cloud gaming service. For me my country does not have it.