This was an answer over on Quora.
For any question that takes the form, “can members of group x do y?” the answer is nearly always going to be, “some will. Some won’t.”
The point, as always, is that in any case where you’re attempting to generalize all gay people into one monolithic class if some members of x do, indeed do y, that still doesn’t tell you anything useful about the class as a whole. It only says something about those members of the class who are x and do, in fact, do y.
Can some gay men (presumably men, given the wording of the question) get along with straight wives? Yes, some can. Closeted gay people of any gender have been marrying people of other genders for as long as human societies have sought to prevent homosexuality.
It hasn’t ever actually prevented anything, but that’s a different discussion.
But the fact that some gay men might be happy in a heterosexual relationship doesn’t really tell you much. It only addresses that subgroup of gay men who can be happy in a straight relationship. It doesn’t say anything about gay people in general, or gay people as a whole. In parts of the world where being gay probably won’t get you killed, where we can live more openly, very, very few of opt for relationships with partners who aren’t the gender(s) we’re attracted to.
In other places, where being openly gay is actively dangerous, sure, lots of gay men will opt for straight marriages. That doesn’t mean much of anything other than a desire to avoid getting hurt or killed.
It doesn’t suggest that those people wouldn’t opt for a same-gender relationship given the right circumstances.
I could marry a woman… we’d probably get along fine. I generally think women are awesome.
But it wouldn’t be anything like my marriage with my husband, and I would actively want that relationship with a man, even if I got along well enough with a woman.