"Sodomy was a very widespread phenomenon": the secret sex lives of China's most infamous pirates

Official records suggest same-sex relations were notably common among the pirates who terrorised the South China Sea in the early 19th-century. But what those relationships meant is hard for history to establish

Early 19th-century illustration showing Chinese pirate vessels attacking and capturing a European boat in the South China Sea.

Published: August 31, 2026 at 11:30 AM

Save

The busy, tropical sea off southern Imperial China in the 19th-century was the maritime home of one of the most dominant pirate organisations in world history. At its height, Guangdong Pirate Confederation operated with hundreds of vessels, and tens of thousands of people.

Ad

This pirate fleet made its name as China's Qing dynasty was at the height of its pre-Opium War power. The Qing state ruled an enormous empire, but policing the long and fragmented coastline of Guangdong and neighbouring provinces was persistently difficult, leaving space for the fleets of the Guangdong Pirate Confederation to organise a highly complex and ordered system of piracy.

But for all that the world of the Guangdong Pirate Confederation is that of typical pirate violence and aggression – terrorising coastal communities and plundering their loot – there seems to have been one facet of life within these criminal fleets that might be more unexpected.

Historian Dian Murray, author of Pirates of the South China Coast, 1790–1810, was studying official records relating to captured pirates. Speaking on the HistoryExtra podcast, she recalled examining around 89 cases concerning pirates apprehended in the South China Sea.

"In around 54 of them, sodomy or homosexual relations were mentioned. I found that to have been a very widespread phenomenon when I did my research," she says. In other words, in most cases where pirates from the Guangdong Pirate Confederation were captured and charged, homosexuality was mentioned among the pirates’ transgressions.

Were romantic and sexual relationships between men genuinely commonplace aboard Chinese pirate vessels? Were these encounters consensual? Did they reflect the overwhelmingly male environment of ships that often spent long periods at sea? Or could sex instead have been used to express hierarchy, domination or initiation within pirate crews?

The records studied by Murray don’t give a straightforward answer. Indeed, Murray stresses that "we don't know". But these records do undoubtedly open an intriguing window onto sex and intimacy in a maritime society very different from our own – and raise a broader problem for historians attempting to understand homosexuality in the past.

What was life like aboard the pirate ships of the South China Sea?

Piracy had long existed along China's southern coastline, but around the turn of the 19th century it expanded dramatically. One of the most important figures in this transformation was Zheng Yi, a pirate leader who helped bring previously competing pirate fleets into a much larger confederation in the first years of the 1800s. He helped forge agreements between major pirate fleets, which were often distinguished by coloured flags. The resulting loose coalition allowed previously rival commanders to cooperate and coordinate operations without surrendering all their independence.

His wife, Zheng Yi Sao, would become even more famous. After Zheng Yi's death in 1807, she played a central role in maintaining the confederation, working closely with another pirate commander, Zhang Bao. So, life within this world was overwhelmingly male, but not exclusively so.

"There were provisions about families on board ships, and certain women were allowed," explains Murray. "If females were captured and held for ransom, some of them could be purchased by the pirates, or they could live with them on board ship," she says.

Precisely how such arrangements operated in practice is much harder to establish. Pirate codes and official accounts can tell historians what was supposed to happen, or what authorities claimed had happened, without necessarily revealing the realities of individual lives. Nevertheless, what is clear is that women were present aboard at least some pirate vessels, and in Zheng Yi Sao’s case, held significant power. That makes the evidence of frequent homosexuality more complicated than a story in which men formed sexual relationships when no women were available.

One particularly important same-sex relationship took place within the complex family at the heart of the pirate confederation.

19th-century engraving of a large fleet of Chinese junks and smaller pirate vessels sailing across the China Sea.

Chinese pirate vessels depicted in 1857, decades after the Guangdong Pirate Confederation had been broken up. At its peak around 1809, the confederation commanded hundreds of vessels and tens of thousands of pirates, demonstrating the extraordinary scale organised piracy had reached along the southern Chinese coast | Credit: Getty Images

Zheng Yi’s relationship with Zhang Bao

Zhang Bao became one of the most powerful figures in the South China Sea pirate world. He had originally been captured by pirates as a young man and was eventually incorporated into the family of Zheng Yi and Zheng Yi Sao.

"When Zhang Bao was taken into the family and adopted, he also had a homosexual relationship with Zheng Yi," says Murray.

Following Zheng Yi's death, Zheng Yi Sao formed a partnership with Zhang Bao. Partly, this was politically expedient: Zheng Yi Sao possessed authority, experience and connections within the confederation, while Zhang Bao commanded the loyalty of a large body of fighting men. Their partnership helped prevent the organisation from fragmenting after Zheng Yi's death. But it was also personal. They had a child together and ultimately married, while Zhang Bao assumed an increasingly prominent position in the pirate confederation.

As Murray describes, this is an incredible transition. “Zheng Yi Sao ultimately, upon the death of her husband, took over the relationship and had a child and was associated with Zhang Bao for the rest of his life."

The resulting family structure might seem unusual to modern eyes. But retrospectively applying modern categories too rigidly can obscure rather than clarify what was happening. A pirate in early 19th-century China having sexual relationships with both men and women does not necessarily tell us how he understood his own sexuality.

What did sex between male pirates mean?

So, homosexual relationship appears to have been sufficiently common to leave a striking footprint in the surviving legal evidence, but "what did all this mean?" Murray asks.

"Did it mean a love relationship at sea, which was not an uncommon thing? Or, did it mean some kind of power drive on the part of a superior vis-à-vis an inferior? Did it mean a kind of initiation?"

"We don't know," Murray says.

A reference to "sodomy" in a legal document tells us that an act was alleged or recorded. It doesn’t automatically tell us what the participants felt about one another, how consensual their encounter was, or what identity – if any – they attached to their sexual behaviour.

This same challenge with understanding the sexualities of the past presents itself elsewhere in history.

In parts of the Classical Greek world, sexual relationships between men could exist within recognised social frameworks, often shaped heavily by age and status. The categories governing those relationships were not equivalent to modern ideas of homosexuality.

Pre-modern Japan likewise had well-documented traditions of male-male sexuality in particular social settings, including among samurai and within Buddhist institutions. Again, such relationships existed within their own cultural systems rather than mapping neatly onto the identities used in the 21st century.

Neither of these examples clarifies the complicated sexual world operating within the overwhelmingly male world of South China Sea piracy. Like a ship drifting through mist and fog, these relationships are obscured by distance, and remain just out of sight.

Ad

Dian Murray was speaking to Emily Briffett on the HistoryExtra podcast. Listen to the full conversation.

Authors

James OsborneSenior content producer

James Osborne is a senior content producer at HistoryExtra

Ad

Ad

Loading...

Ad

Loading...