The United States starting eleven line up on the field before a FIFA World Cup qualifier game between Costa Rica and USMNT at Estadio Nacional de Costa Rica Wednesday in San Jose, Costa Rica.
CNN  — 

After an eight-year wait, the US Men’s National team secured a spot Wednesday in the 2022 FIFA World Cup, although not in a way the team would have preferred.

In its 14th and final match of CONCACAF World Cup qualifying, the US clinched a spot with a 2-0 loss against Costa Rica at Estadio Nacional in San Jose, Costa Rica.

“I’m extremely proud of this group,” US star Christian Pulisic said. “It’s a bit of a weird feeling right now because I hate to lose so much, but I’m really proud, and I can’t wait to go to the World Cup.”

Entering Wednesday night, the US knew it could punch its ticket with a win, draw or loss by less than six goals.

The top three teams in CONCACAF automatically qualify for the World Cup, while the fourth-place team will compete in an intercontinental playoff against Oceania’s qualifying tournament.

The final table shows the US in third position, behind Canada and Mexico, who also qualify. Costa Rica finished fourth.

This will be the first men’s World Cup appearance for the US since 2014. The US did not qualify for the previous men’s World Cup in 2018, having finished fifth in CONCACAF World Cup qualifying.

The 2022 World Cup will be held in Qatar and is scheduled for November 21 through December 18.

CNN’s Jill Martin contributed to this report