NASA scientists are hoping to capture photographs and data a once in a million years encounter in space.
A giant comet, which is the size of a small mountain, is due to pass Mars this evening.
The comet, known as Siding Spring (C/2013 A1), is set to hurtle past Mars at a distance of about 141,600 km - less than half the distance between Earth and our moon.
The closest pass is expected to happen Sunday at 7.27pm.
Astronomers do not expect it will come anywhere near colliding with Mars, but they do hope it will be close enough to reveal clues about the origins of the solar system.
The comet is believed to have originated billions of years ago in the Oort Cloud, a distant region of space at the outskirts of the solar system.
The comet - which is around a mile wide - is flying through space at a speed of just under 200,000km/h.
NASA has manoeuvred its Mars orbiters to the far side of the planet so they will not be damaged by the comet's high-speed debris.
Even as the Mars Reconnaissance Orbiter, Mars Odyssey and MAVEN have been repositioned to avoid hazardous dust, scientists hope they will be able to capture a trove of data about the flyby.
NASA's two rovers - Curiosity and Opportunity - will turn their cameras skyward and send back pictures of the comet's pass in the coming days, weeks and months, the US space agency said.
StarDate editor Rebecca Johnson said: "The orbiters will keep a close eye on the show.
"They'll study the comet itself, which is a small chunk of ice and rock. They'll also study the cloud of gas and dust around the comet, as well as its long tail," she said. "And they'll measure how the gas and dust interact with the Martian atmosphere."
The comet has travelled more than one million years to make its first pass by Mars, and will not return for another million years, after it completes its next long loop around the sun.
It was discovered at Australia's Siding Spring Observatory in January 2013.
Its close encounter with Mars is not likely to be visible to sky watchers on Earth.
However the near miss is of great interest to scientists, particularly since there are so many spacecraft on and around Mars to record it.
"As it zips toward the sun, it gives scientists a chance to see a relic from the distant past - a snowball that preserves the same ingredients that gave birth to our own world," said Johnson.