For the life of me I can't recall ever hearing of one which means they're either really good or they don't exist.
Yes, China has long had official organizations aimed at intelligence collection, espionage, counter-intelligence, and all other manners you might think fall under the purview of a "spy agency". From the "Embroidered Emissaries" (绣衣使者, Xiu Yi Shizhe) of the Han Dynasty, to the "Li Jing Guard" (丽竞门 Lijing Men) of the Tang, Chinese emperors sought to have eyes and ears everywhere they could to maintain order.
But the largest and probably most famous of the imperial-era's secret services was during the Ming Dynasty (1368-1644), whose emperors employed the Jinyiwei (lit. the "Brocade-clad Guard") as both the personal bodyguards of the royal household, as well as wide autonomy to arrest, question and punish vitually anyone anyone, even including nobility and the imperial clansmen. They were likewise empowered to collect military intelligence against enemy agents and participate in battle planning.
The Manchu-led Qing Dynasty dissolved the Jinyiwei, and never seemed to have really got the ball truly rolling on an effective replacement. Its 5th emperor, the Yongzheng Emperor of the early 1700's, established a sort of secret police called the Zhan Gan Chu, but it's unclear how effective or to what extent it operated. More widely, the Qing attempted to utilize an innovation of the earlier Song Dynasty, the Baojia system, which was in essence to create discrete social units of families (think: a neighborhood... under Qing law, one Bao was 1000 households, so a sizeable number... they were subdivided into Jia - 100 households, and pai 0 10 households) all tasked with policing and enforcing one another... and if one member was found to be in violation of the rules, then the whole sub-collective was punished (at least, those who didn't rat the offender out). This was widely and historically panned as ridiculously ineffective, and largely just ignored, especially in the latter stages of the Qing as it slipped into malaise.
Once the Imperial System had fallen to the Republic of China, the Guomingdan Party under Jiang Jieshi set up its own agency, the Bureau of Investigation and Statistics (軍統, Juntong), which was primarily employed as secret police within the populace and specialized in kidnappings, assassinations, and surveillance. Nevertheless, during the Second Sino-Japanese War, they were repurposed to espionage and counterintelligence against the Japanese Imperial Army occupiers.
With the rise and eventual war between the KMT and the Chinese Communist Party of Mao Zedong, the CPC formed and operated its own Central Department of Social Affairs (中央社会部, Zhongyang Shehui Bu) out of Yan'an in Shaanxi Province between 1939 and 1949, until it was replaced by the...
The Chinese Ministry of State Security (国家安全部, Guojia Anquanbu), which fills that role in the modern PRC, and has been in place since the formation of the state in 1949. Its mission statement as an organ of the CPC is to keep track of and neutralize perceived "enemies" of the ruling Party, or in its own words to "“to control the Chinese people to maintain the rule of the Communist Party”. It's more or less a direct Chinese emulation of the KGB, and is easily on the list of the modern world's top intelligence agencies... It's not for nothing that every few months the American media goes into a panic over the CHINESE AR HACKIN AR EMAILS!!! It has had considerable successes in penetrating foreign agencies, most notably the US'. Some of the more infamous "outings" of its agents were Jin "Larry" Wudai, a translator for the CIA, who went undetected for some 4 decades before finally being outed and charged with espionage in the 1985. He admitted his part in espionage and subsequently committed suicide via asphyxiation while awaiting transport to a Federal Prison (there have been more recent arrests as well, but that falls within the 20 year blackout zone of this sub).
Assessing the Global policy Influence of the Ministry of State Security
"The 'Flying Guillotines' and Yongzheng's political spies" (CN lang.)
Yang Jianying (ed.). Collected Material on the Organizational History of the Chinese Communist Party (CN lang.)
So I'm slightly confused as to what you're looking for as the KGB and MI5 would have shared some tasks and not others. The KGB was divided into multiple directorates who had their own responsibilities from foreign intelligence gathering to domestic counter-intelligence. MI5 was responsible for the latter.
The Ministry of State Security would then be your equivalent branch in the PRC. An article about a defector from them.
The PLA also maintains its own intelligence gathering organization, the Second Division, in case you were looking for military spying organization. Again mentioned in the article above.
There's also a book on Chinese spying efforts 'Tiger Trap' by David Wise, which while I'm unsure of its exact academic merits (and reviews seem to be mixed) is at least an interesting read.