CNN anchor Anderson Cooper, who has been reluctant to talk about his personal life in public, revealed that he is gay in an essay posted online on Monday.

The celebrity journalist and host of the current affairs program 360º said he had kept his sexual orientation private for personal and professional reasons but came to think that remaining silent had given some people a mistaken impression that he was ashamed.

"The fact is, I'm gay, always have been, always will be, and I couldn't be any more happy, comfortable with myself and proud," he wrote in a letter to well-known commentator Andrew Sullivan, who writes the blog the Dish for the news website the Daily Beast.

The letter was written in response to Sullivan asking Cooper his thoughts on an Entertainment Weekly story about the recent tendency for gay people in the public eye to come out in a more restrained way than in the past. Cooper, a personal friend of Sullivan, gave Sullivan permission to publish his email response.

Cooper, the son of U.S. heiress Gloria Vanderbilt, had long been the subject of rumours about his sexual orientation. He said that in a perfect world, it wouldn't be anyone's business but that there is value in "standing up and being counted."

"I still consider myself a reserved person, and I hope this doesn't mean an end to a small amount of personal space," he wrote. "But I do think visibility is important, more important than preserving my reporter's shield of privacy."