The royal brothers appeared at a nature reserve outside of the capital, Gaborone. Prince Harry uttered "Whoa!" when the snake wrapped itself around his neck and urinated twice as William held it in his hands, The Times of London reported Tuesday.
"It's peeing," William said as the snake relieved itself. "It's obviously very relaxed."
The brothers were also offered their choice of snakes to be named for them at the Mokolodi Education Center.
"Big brother chooses the python, little brother gets the common brown," said William, who was given first pick. "It's the same color as your hair."
"Mine will bite you," Harry joked in return.
Prince William is a patron of the charity Tusk Trust, which supports the nature center financially.