The relationship between China and Japan spans thousands of years. Japan has deep historical and cultural ties with China; cultural contacts throughout its history have strongly influenced Japan – including its writing system architecture, cuisine, culture, literature, religion, philosophy, and law. China, in return, has been deeply influenced by Japan. After the Meiji Restoration in 1868, the Empire of Japan embraced Westernization and saw the Qing dynasty as "non-Chinese", leading to the First Sino-Japanese War where Japan emerged victorious and gained control of Taiwan. In the 20th century, Japan pursued an increasingly expansionist policy towards China. In 1931, Japan invaded Manchuria, establishing the puppet state of Manchukuo, and invaded other parts of China in 1937, precipitating the Second Sino-Japanese War which was marked by numerous Japanese war crimes. Japan surrendered in 1945, leading China to regain all lost territories. After the establishment of the People's Republic of China in 1949, relations were tense, with Japan continuing to recognize the Republic of China which had retreated to Taiwan, though informal ties with the PRC existed.
Japan normalized relations with the PRC in 1972 with the Japan–China Joint Communiqué, recognizing PRC as the only legitimate representative of China. The Treaty of Peace and Friendship between Japan and China was signed in 1978. During this time, trade between the two nations grew significantly. Relations further improved when Japanese emperor Akihito visited China in 1992 and Prime Minister Tomiichi Murayama issued a statement in 1995 apologizing for Japan's actions during World War II. Ties between the two nations deteriorated after anti-Japanese demonstrations in 2005. The 21st century marked a changing balance of power between the two countries; Japan's economy stagnated following the Lost Decades that started in the 1990s, while China's economic and military power grew significantly after the beginning of reform and opening up in 1978. In 2010, China's economy overtook Japan. Relations deteriorated in 2012, triggered by the Japanese government's purchase of the disputed Senkaku Islands from their private owner, which led to anti-Japanese protests. Relations started to improve in the late 2010s and 2020s, but deteriorated in 2025 after comments made by Prime Minister Sanae Takaichi regarding a potential defense of Taiwan.