The Solar Impulse team said it was drawing up a new itinerary for the challenge in Morocco's desert after the plane made a U-turn almost eight and a half hours into the 16-hour flight from Rabat to the city of Ouarzazate.
After the experimental plane arrived back at Rabat shortly before midnight (2155 GMT) on Wednesday, Solar Impulse spokeswoman Alexandra Gindroz told AFP:
"We are studying the meteorological conditions to choose another attempt for Ouarzazate or another solution."
The mission said earlier on the Solar Impulse website that the plane and pilot Andre Borschberg "are not in danger, but (the headwind) is hindering the advancement of the Solar Impulse to its final destination."
"The flight director has made the decision to turn back to the departure airport Rabat," it said.
The turnaround underlined how vulnerable the giant high-tech aircraft, which has the wingspan of a jumbo jet but weighs no more than a medium-sized car, is to natural weather conditions.
The pilot has a parachute in his tiny cockpit.
Fitted with 12,000 solar cells feeding four electric motors, the Swiss-built plane flies without using a drop of fuel.
Last week, it flew into history books as it completed the world's first inter-continental flight by a solar plane, flying from Spain to Morocco, a feat that capped a string of other firsts, including the first manned plane to fly around the clock on the Sun's energy in July 2010.
It also holds the record for the longest flight by a manned solar-powered plane after staying aloft for 26 hours, 10 minutes and 19 seconds above Switzerland, and has also set a record for altitude by flying at 9,235 metres (30,298 feet).
Ahead of Wednesday's flight, organizers said it would be the "most difficult the plane has ever undertaken due to the hot and dry nature of the climate as well as the proximity of the massive Atlas mountains" which tower up to more than 3,000 metres.
Flying above the Moroccan sand dunes -- the backdrop to the 1962 British cinema epic "Lawrence of Arabia" -- poses particular challenges such as thermal currents, strong winds and thunderstorms.
Earlier in the day, Borschberg had told AFP by satellite phone that the flight was going well and that he was planning to follow the coast, passing Casablanca and Marrakech -- at the foot of the Atlas mountains, before reaching Ouarzazate.
But he had also said he expected strong winds later in the evening in the Atlas region.
Last month, the solar-powered aircraft made the 2,500-kilometre (1,550-mile) journey from Madrid to Rabat, its longest to date, after an inaugural flight to Paris and Brussels last year.
The flights are intended as a rehearsal for the goal of a round-the-world trip in 2014 by an updated version of the plane.
The flight is live-streamed on the project's website www.solarimpulse.com.