How far is Mars from Earth?
- At their closest
- about 0.37 au roughly 56 million km, near a favourable opposition
- At their furthest
- about 2.68 au roughly 400 million km, on opposite sides of the Sun
There is no single answer
Mars and Earth are both moving, on orbits of different sizes and different periods, so the distance between them is never the same twice. It runs from roughly 0.37 astronomical units when they pass close, about 56 million kilometres, out to roughly 2.68 au when they are on opposite sides of the Sun, about 400 million. That is a range of more than seven to one, which is why a page that quotes one number is answering a different question from the one you asked.
Why the close approaches vary too
Earth and Mars line up on the same side of the Sun roughly every 26 months, but not at the same distance each time, because Mars's orbit is noticeably out of round. When they meet with Mars near its closest point to the Sun the gap is much smaller than when they meet with Mars near its furthest. Missions are launched around the favourable ones.
Seeing it instead of reading it
The model draws both planets from published JPL orbital elements, so moving the date shows the gap opening and closing rather than describing it. Switch to Accurate mode and the distances are true to scale, which is when the emptiness between them stops being an abstraction.