Pirates were often rampant near the southeast coast in the Ming Dynasty, and some people in Japan and neighboring island countries constantly harassed the residents in the coastal areas of Guangdong and Fujian, and the people were miserable.
So the Ming Dynasty issued an order that the whole country implemented the "sea ban" policy, and residents in coastal areas were not allowed to fish in the sea and moved inland for a certain distance to cope with the invasion of pirates.
In the Qing Dynasty, Emperor Qianlong, whose eyes were higher than the top, felt that China was vast in territory and abundant in natural resources, and he could be completely self-sufficient even if he didn't need to trade with foreign countries.
Therefore, for fear of missing the vast China, Qianlong personally ordered the whole country to implement the policy of "closing the country to the outside world", leaving only five ports for trade.
As a result, China's neglect led to the gradual loss of China's sea power.