An asteroid as long as the Golden Gate Bridge will pass harmlessly by Earth on Friday as NASA and private firms aim to explore or commercially exploit these rocky interplanetary bodies rich with precious metals and rare minerals.

But coming just three months after a meteor explosion injured more than 1,000 people in Russia, the flyby also will point up the need to hunt down and track asteroids that threaten Earth — to develop capabilities to deflect incoming asteroids that could cause planetary catastrophe.

“In response to a question we always get — ‘Can you protect the planet?’ — the answer to that is ‘no,'” NASA Administrator Charlie Bolden, a former astronaut, said Thursday on the eve of asteroid 1998 QE2’s closest approach to Earth.

“But if we’re able to get into space, and humans are able to redirect an asteroid, or deflect it in some slight way, we may be getting close to the day when we can say, ‘Yes, we can protect the planet.’ ”