Three missions to Mars are getting ready to launch in the next few weeks. Why are all these missions launching at the same time?

4:50 a.m. PDT on July 30. Image credit: NASA Mars 2020.

They are all timed to match the upcoming Mars opposition on October 13th, 2020. When Mars is at opposition, Mars and the Sun are on opposite sides of the Earth. At opposition, Mars is also at its closest point to the Earth, making it more fuel-efficient for a spacecraft to reach the red planet.
Missions to Mars are often designed to follow a Hohmann transfer orbit to move a spacecraft from a lower circular orbit to a higher circular orbit using the least amount of fuel. A Hohmann transfer orbit involves an initial burn to push the spacecraft into an elliptical orbit, coasting most of the way to the higher orbit, then a second burn to put it into a circular orbit. To meet up with Mars, the transfer orbit also needs to be timed so that the spacecraft reaches the higher orbit at the same time that Mars is there – this timing requirement leads to launch windows that occur a few months before each opposition of Mars. The Mars Insight spacecraft (https://mars.nasa.gov/insight/) launched in May 2018, with the trajectory below, was timed to match up with Mars’ last opposition in July 2018.

Oppositions of Mars occur approximately 26 months apart so missing a launch window means a delay of over two years.
United Arab Emirates – Emirates Mars Mission
Launch Window: July 14 to Aug 12
This science mission from the United Arab Emirates (UAE) — the first by an Arab-Islamic country — will blast-off from Tanegashima Space Center, Japan. The “Hope Probe” seeks to provide a better understanding of the Martian atmosphere and its layers, including the loss of hydrogen and oxygen gases into space over a Martian year.
China National Space Administration (CNSA)’s – Tianwen-1
Launch window: July 23 to Aug 15
The Tianwen-1 mission (known as Huoxing-1, HX-1 during development) will be China’s first Mars orbiter, lander and rover. It will deploy an orbiter around Mars and land a rover on the surface on April 23, 2021. Its stated objectives are to search for evidence of both current and past life and to assess the planet’s environment.
NASA Mars 2020
Launch Window: July 30 to Aug 15
The Mars 2020 mission addresses key astrobiology questions about the potential for life on Mars. The Perseverance rover includes a drill that can collect core samples of the most promising rocks and soils and set them aside in a “cache” on the surface of Mars – ready to be returned to Earth in a future mission.
Delayed: European Space Agency – ExoMars
A fourth mission, the ESA’s ExoMars mission, was originally scheduled to launch in 2020. However, the COVID-19 pandemic impacted the timelines for testing vital parachutes & electronics and forced a delay. But since oppositions of Mars happen every 26 months, the launch has been postponed by over two years to 2022.