Think about the amount of energy you expend on flat ground.
Use the same amount of energy on the stationary bike after dialing in a resistance that feels right.
If the speed reads differently, then you need to adjust by the ratio of speeds between your road speed and the exercycle.
The ratio and settings differs by exercycle brand, and perhaps by specific exercycle. The one I use most I run at level 3 or 4 and multiply my ending mileage by 2/3 to approximate an equal ride on the road.
Actually the way I did it also works... ride for one hour on each with the same level of effort and see how the resulting distance varies...
__________________
Slow Ride Cyclists of NEPA
People do not seem to realize that their opinion of the world is also a confession of character.
- Ralph Waldo Emerson