China told Indonesia to stop drilling for oil and natural gas in maritime territory that both countries regard as their own during a monthslong standoff in the South China Sea earlier this year, said four people familiar with the matter.

The unprecedented demand, which has not previously been reported, elevated tensions over natural resources between the two countries in a volatile area of global strategic and economic importance.

One letter from Chinese diplomats to Indonesia's foreign ministry clearly told Indonesia to halt drilling at a temporary offshore rig because it was taking place in Chinese territory, according to Muhammad Farhan, an Indonesian lawmaker on parliament's national security committee, which was briefed on the letter.