This article needs additional citations for verification. (December 2019)
On 1 August 1886 (Meiji 19), the Qing dynasty's Beiyang Fleet, consisting of four warships, the Dingyuan, the Zhenyuan, the Jiyuan, and Weiyuan, entered the Nagasaki harbor port during a visit to various major Asian harbours. At that time, the Qing dynasty was much stronger than Japan. The Dingyuan was a heavier ship than the heaviest Japanese cruisers, due to Japan's policy of following the Jeune École naval strategy, which emphasized small rapid assault craft. In addition, Japan had suffered a setback during the Gapsin Coup in which 400 outnumbered Japanese soldiers were defeated by 2000 Qing-Joseon soldiers.
On August 13, 500 Chinese troops took part in shore leave. They went to the red-light district, where during an altercation with locals, damaged fixtures were blamed on the soldiers. Locals also claimed that drunken Chinese soldiers went around the city pursuing women and children, causing outrages. Nagasaki Prefecture Police Department tried to intervene together with a large number of local civilians. As a result, the policemen and Chinese sailors, using swords purchased from stores, began to fight hand-to-hand in sword battles within the city, causing at least 80 deaths.  As a result, a sense of unrest thus pervaded.
On August 14, at a conference between the governor of Nagasaki prefecture, Kusaka Yoshio, and the Qing consulate Xuan Cai, the Qing navy prohibited its soldiers from going on land as a group for one day, and agreed that when soldiers are on leave, they would be overseen by an officer.
On August 15, at around 1:00 PM, about 300 Chinese troops went ashore, following the cessation of the agreement. Some were armed with clubs. Some Chinese sailors attacked three police officers, resulting in one death. A driver of a rickshaw (jinrikisha) who saw this was indignant about this, and tried to punch a Chinese sailor. In response, the Chinese sailors began to riot. Thus, another big incident began as the policemen who came to stop this and the Chinese sailors once again began fighting, with various casualties. On the Qing side, 1 officer died and 3 were injured, and 3 soldiers died and at least 50 were injured. On the Japanese side, 3 police officers were injured, 2 constables were killed, and 16 were injured. Several tens of Japanese civilians were also injured.
Effects of the incident
Combined with the Gapsin coup of 1884 (Meiji 17), this incident stirred up anti-Qing sentiment and was a distant cause to the First Sino-Japanese War. Also, Toyoma Mitsuru created the political association called the Genyosha, which was the first turning away from civil rights theory to sovereign rights theory.
After the incident, the Qing did not apologize to Japan, and behaved with confidence believing in the superiority of their navy. At that time, the Qing possessed the newest model of navy battleships, the Dingyuan. It was thought that the Japanese navy could not match this ship at this time, having a heavier tonnage than modern French built Japanese cruisers. (The Dingyuan was eventually scuttled after the Battle of Weihaiwei in 1895.) Japan's setback during the Gapsin Coup, in which 400 Japanese soldiers had been driven off by 2000 Qing soldiers was still recent and fresh.
The Qing made demands to the Japanese government that from then on the Japanese police would not prohibit the wielding of swords, in which they succeeded and Japanese were forced to make a large sum of reparation.  However, as a result of this incident, anti-Qing sentiment rose in Japan, presaging further confrontation.
In addition, the event also produced another consequence: the cracking of the Qing intelligence code. A Japanese man named Wu Oogoro picked up a Beiyang Navy sailor's dictionary which was marked with 0-9 between the Chinese characters (Kanji). The Japanese intelligence department subsequently analysed these characters and figures and determined it was a guide to decipher the Qing codes. In order to completely crack the code, Japanese Foreign Minister Mutsu Munemitsu deliberately provided a writing in Chinese characters of moderate length to the Qing ambassador Wang Feng Cao. The next day the Japan Telecom legation successfully intercepted the telegram sent by the embassy to Zongli Yamen. Sato Yoshimaro, a bureaucrat in the telecom legation used this kanji text with known content to crack the Qing code. This had effects similar to the cracking of the Enigma and handed Japan an advantage in the First Sino-Japanese war.
- JACAR（アジア歴史資料センター）Ref.B07090388600、帝国造船所二於テ外国船艦修理方請願雑件第3巻「清国軍艦長崎ニ来航修繕スル様李鴻章ヘ勧告ノ儀ニ付在天津領事ヨリ申出ノ件」（外務省外交史料館）。事件の翌年、1887 8月、波多賀承五郎 天津 領事 が 井上馨 外務大臣に問い合わせた「機密第六号」のなかにつぎの文言がある。「先年修繕ノ為メ長崎ニ軍艦ヲ発遣シタルニ不図モ意外ノ葛藤ヲ生シタルニ付再ヒ長崎ニ軍艦ヲ派スルコトハ支那官吏ノ決シテ為サザル所ニ有之」。
- 『伊藤博文 文書 第34巻 秘書類纂 長崎港清艦水兵喧闘事件』所収、明治19年8月15日付・ 司法大臣 山田顕義 宛長崎 控訴院 検事長 林誠一発「長崎事件第三報」(53～58頁)のうち、55頁に「携フ所ノ日本刀（此刀ハ古道具屋ヨリ買取所持シ居タルモノナラン）」とある。
- Grounds of Judgment: Extraterritoriality and Imperial Power in Nineteenth Century P135
- 岡崎久彦「明治の外交力 陸奥宗光の蹇蹇録に学ぶ」海竜社、2011年
- Qing Dynasty Before the fight prostitution in Japan leaked telegram password (Figure) Archived July 29, 2014, at the Wayback Machine
- "马关议和清政府密电问题考证补" (in Chinese). Retrieved 27 February 2015.