Christen Press celebrates her goal early in the second half Tuesday in Alicante, Spain. (Manuel Lorenzo/EPA-EFE)

With the Women’s World Cup in France 4 1/2 months away, U.S. Coach Jill Ellis felt it necessary to pull her top-ranked national team out of its comfort zone — namely, almost always playing at home.

There will be ample opportunity this spring to entertain crowds from coast to coast and to remind the masses that the women here are more successful at this game than the men. Thousands of American fans have booked trips to France, and many more will enjoy the pep rallies.

At this point, however, the U.S. squad requires challenges on unfamiliar grounds against quality opponents doing their own preparation for the World Cup.

A visit to third-ranked France on Saturday promised a major test — it did not go well — and a stop in Spain on Tuesday to face the No. 12 team offered a meeting with one of many traditional soccer countries that has finally begun to appreciate that women enjoy playing the game, too.

With several U.S. starters resting, the first game exposed flaws in the depth chart — and showed that France is a legitimate title contender. With a stronger cast against a weaker foe Tuesday, the second act began with alarm but got better after halftime and resulted in a 1-0 victory in Alicante, Spain.

Christen Press scored eight minutes into the second half on a terrific individual effort.

Ellis also took her team to Europe two months ago, albeit to face lighter competition (Portugal and Scotland). Before that, the Americans had played 26 of 27 matches at home. The only time they required passports in that span was to visit Vancouver.

The four games in Europe were all friendlies, inconsequential gigs featuring a little experimenting and a lot of substituting. Ideally, though, the matches have reminded the U.S. players of the difficulties of playing on foreign land and, as current titleholders and longtime standard-bearers, they’ll have a target on their backs this summer.

They will not return to Europe — or venture anywhere, for that matter — until they board a transatlantic flight on or around Memorial Day. Until then, they will play eight tuneups in seven states in four time zones. The home tour starts Feb. 27 in suburban Philadelphia against Japan — a rematch of the past two World Cup finals — and ends May 26 vs. Mexico in Harrison, N.J.

Barring a spate of injuries, Ellis has a good idea of whom she will bring to France (23 players from a pool of about 28). She also knows the formation (four defenders, a triangle in central midfield and three forwards) as well as her preferred starters.

Ellis held back a bit in her lineup selections Saturday in the eventual 3-1 loss to France, the greatest threat to dethroning the reigning champions this summer. Against almost all opponents, the Americans can get away with a mixed lineup. Against France, the absence of wingers Megan Rapinoe and Tobin Heath and defensive midfielder Julie Ertz — as well as a trial by fire for young left back Emily Fox — was exploited.

Injuries and illness factored into Ellis’s decisions, but she was also wary of showing her cards before a possible showdown with the French in the World Cup quarterfinals in Paris. There was also a fitness factor: U.S. players compete in the National Women’s Soccer League, which has been out of season since October and will not resume until training camps open March 4.

On Tuesday, against a Spain side that has not evolved as quickly as France has, Ellis started the group (with the possible exception of injured defender Kelley O’Hara) that is expected to be on the field June 11 in the World Cup opener against Thailand in Reims. (She made the maximum six substitutions in the second half.)

Aside from being at almost full power, the Americans were surely motivated by the lopsided loss they suffered three days earlier, which had extinguished a 28-game unbeaten streak spread over 18 months. The Spaniards' comfort and skill with the ball showed they have a bright future and could pull a surprise or two this summer. They don’t, however, seem ready to join the top tier of the women’s game.

Press — a starter Saturday and a halftime entry Tuesday — broke the deadlock in the 54th minute. She roared out of midfield to start a 50-yard run, then pierced the penalty area and angled a low shot that beat goalkeeper Sandra Panos.

Irene Hernandez’s desperation slide nudged the ball into the net, but Press deserved all the credit. The lead stood up against mild threats, a positive response to the weekend’s rare and humbling defeat.

More soccer coverage from The Post:

Survival chances are ‘slim’ as search is suspended for Emiliano Sala, whose plane went missing over the English Channel

D.C. United, goalkeeper David Ousted seem close to parting ways

Americans abroad: Tim Weah, Ian Harkes, Hailie Mace score in debuts