Neither of the two giant planets is a likely abode for life as we know it. But, Dr. Gaudi said, warm rocky planets  suitable for life  could exist undetected in the inner parts of the system.

“This could be a true solar system analogue,” he said.

Sara Seager, a theorist at the Massachusetts Institute of Technology who was not part of the team, said that “right now in exoplanets we are on an inexorable path to finding other Earths.” Dr. Seager praised the discovery as “a big step in finding out if our planetary system is alone.”

Since 1995, around 250 planets outside the solar system, or exoplanets, have been discovered. But few of them are in systems that even faintly resemble our own. In many cases, giant Jupiter-like planets are whizzing around in orbits smaller than that of Mercury. But are these typical of the universe?

Almost all of those planets were discovered by the so-called wobble method, in which astronomers measure the gravitational tug of planets on their parent star as they whir around it. This technique is most sensitive to massive planets close to their stars.

The new discovery was made by a different technique that favors planets more distant from their star. It is based on a trick of Einsteinian gravity called microlensing. If, in the ceaseless shifting of the stars, two of them should become almost perfectly aligned with Earth, the gravity of the nearer star can bend and magnify the light from the more distant one, causing it to get much brighter for a few days.