This article seems to be the most comprehensive. The summary:
The simple truth of the matter is that a wager never took place. It never happened, end of story.
Having said that however, the possibility does exist that a series of conversations between the two authors and commentary made by Heinlein, may have been the catalyst for Hubbard’s authorship of Dianetics. Heinlein and Hubbard were close friends and Hubbard greatly respected Heinlein, his opinions and his ideas.
Mr. Patterson revealed to me, "RAH and LRH had one or more discussions during 1944 and or 1945 when they were both in Philadelphia, and RAH pointed out to LRH that religions had an inordinate amount of legal latitude in the U.S. and that churches could engage in a great many activities otherwise thought of as secular, under the tax and other protection churches enjoy. He had already explored these ideas in some of his stories and was to revisit these notions in their original form in Stranger. It is possible that this conversation or series of conversations took place as late as December 1945 or early 1946 and in Los Angeles."
As per Wikipedia article on bar bets (... from the "last places you'd think to find things" category :)
It is widely believed that the creation of Scientology was the result of a bar bet between L. Ron Hubbard and Robert A. Heinlein. The story says L. Ron Hubbard dared that he could create a religion all by himself. According to Scientology critic Lindsay this is "definitely not true", no such bet was ever made, it would have been "uncharacteristic of Heinlein" to make such a bet, and "there's no supporting evidence". However, several of Heinlein's autobiographical pieces, as well as biographical pieces written by his wife, claim repeatedly that the bet did indeed occur.
Please note that the "biographical pieces" does NOT refer to the main RAH "biographical" book, "Grumbles from the Grave" - a full text search found no mentions of 'bar', 'bet', 'religion', 'hubbard' or 'dianetics' in the desired context.
The only other place it can be is a bunch of letters in RAH/VH archives, but those cost a lot of money to access online ($3-$12 per archive item) and as such I'm afraid I won't be able to confirm/deny using those; but I included the URL for those who may want to.