When NASA embarked on the Apollo program to land men on the moon, no one was entirely sure how it was going to work.

There were a lot of unknowns, including details about the lunar surface and how a payload as heavy as a manned spacecraft could land there. To gather data to this end, NASA launched the Surveyor program, a series of soft-landed payloads designed to find a way for the agency to safely land men on the surface.

Surveyor 3 was the second successful landed payload, and the only one to intersect the Apollo program directly; pieces of the spacecraft were recovered by the Apollo 12 crew.

PHOTOS: Epic Views of Apollo’s First Moon Rover

The Surveyor program’s goals were three-fold: to develop and validate Apollo soft-landing technology; to gather data on the compatibility between Apollo’s landing system and the lunar surface environment; and to generally add to NASA’s scientific understanding of the moon. There were also secondary goals still in support of Apollo, like photographic imaging of the moon to help scientists pick the right landing spots for the manned missions.

The Surveyor spacecraft all followed a basic design. The main body — on which the power, communications, propulsion, flight control, and payload systems were attached — sat on three hinged landing legs fitted with shock absorbers to soften the impact of landing and wide footpads. The whole lander was a little under 10 feet tall and weighed a little over 2,260 pounds at launch. When the spacecraft landed, having burned through their fuel using retrorockets, the spacecraft weighed just over 650 pounds.

ANALYSIS: Apollo 12 Playboy Stowaway to be Auctioned

For its mission, Surveyor 3 had a few design changes in line with its unique goals. Unlike the previous Surveyors, this third spacecraft was fitted with a television camera, a soil mechanics experiment, and instruments to measure the surface’s temperature and radar reflectivity. After making a soft landing, the spacecraft was designed to take television pictures of the surface and gather data on the surface’s bearing strength, radar reflectivity, and thermal properties.

Surveyor 3 launched from NASA’s Kennedy Space Center on April 17, 1967, atop an Atlas-Centaur rocket. After a brief hold in Earth orbit, the Centaur restarted to send the spacecraft on a course for the moon. It arrived three days later on April 20. Just over 47 miles from the surface, traveling at 8,615 feet per second, the retrorockets roared to life and slowed the spacecraft to a gentle 450 feet per second. Descent continued, monitored by Doppler and altimeter radars.

PHOTOS: The Gemini Missions: Paving the Path for Apollo

A few seconds before landing the radars lost lock; scintillations from the landing site interfered with both systems. The guidance system switched to an inertially-controlled mode that stopped the retrorockets from firing, so after the spacecraft touched down it lifted back off the moon. It touched down a second time, but the continuously firing retros meant it leaped off the surface again. Finally, on the third attempt, the spacecraft settled softly, slid about a foot in the dust, and came to a rest on a 14 degree slope inside a crater in the Oceanus Procellarum, the Ocean of Storms. Within an hour the first images were taken and within two days the surface sampler tool was used.

Surveyor 3 lasted through a full, two-week long lunar day, finally going silent after lunar sunset on May 3, 1967; the spacecraft never woke up after the two-week long lunar night. Over the course of the mission the spacecraft spent 18 hours, 22 minutes digging small trenches in the surface and gathered 6326 pictures. It also gathered a wealth of new data on the strength, texture, and structure of lunar material, all of which was remotely sent back to Earth.

PHOTOS: Moonwalkers: Stunning Photos from Apollo 11

But the last remote transmission wasn’t the end of Surveyor 3’s mission, nor was it the last interaction NASA scientists would have with the spacecraft. On Nov. 19, 1969, Apollo 12 touched down less than 600 feet from Surveyor 3, an incredibly precise landing on only the second lunar landing mission.

Commander Pete Conrad and Lunar Module Pilot Al Bean visited the spacecraft on their second moonwalk. They examined Surveyor 3 and its resting site, photographed the spacecraft, and removed about 22 pounds of hardware to bring back to Earth. Among the recovered pieces was the TV camera, which is now on display at the Smithsonian Air and Space Museum in Washington, D.C.

The whole Surveyor program saw seven spacecraft built and launched to the moon for a total cost of $469 million. The program amassed a wealth of incredibly valuable data that played no small part in supporting the Apollo program. Both Surveyor 3’s mission and Apollo 12’s were considered complete successes by NASA.