BEIJING—China banned all coal imports from North Korea starting Sunday, a move that steps up a prohibition Beijing enacted last year and comes as recent actions by Pyongyang test relations between the two allies.

The temporary ban, which the Ministry of Commerce said would remain through the end of this year, follows North Korea’s launch of a ballistic missile into the Sea of Japan this month, in defiance of international sanctions.

...