A US Navy sailor in California has been convicted of espionage for selling the force's secrets to a Chinese agent who recruited him through social media.

Jinchao Wei, 25, was convicted of six charges, including espionage, conspiracy to commit espionage, and unlawful export of classified data about US Navy ships.

"The defendant's actions represent an egregious betrayal of the trust placed in him as a member of the US military," US Attorney Adam Gordon said in a statement after the verdict was read.

"By trading military secrets to the People's Republic of China for cash, he jeopardised not only the lives of his fellow sailors but also the security of the entire nation and our allies."

Wei, also known as Patrick Wei, was arrested in August 2023 on espionage charges as he arrived for work on the amphibious assault ship, the USS Essex.