ST. LOUIS — Stanford hadn’t been to the NCAA tournament in six years, and the Cardinal doesn’t want to go home.

There was no sense of satisfaction after a 58-53 win over No. 7 seed New Mexico on Friday at the Scottrade Arena. Stanford is only looking forward.

“Coach tells us, a lot of teams are just happy to be here,” senior forward Josh Huestis said, referring to Stanford coach Johnny Dawkins. “Only a handful of teams thinks they can actually win the thing. We’re going to be one of those teams.”

Stanford (22-12), making its first NCAA appearance since 2008, made its first six shots for a 20-4 lead, watched the Lobos (27-7) pull even by midway through the second half, then delivered big plays down the stretch.

Winning, not merely being here, is the 10th-seeded Cardinal’s focus. “This is what we play for,” center Stefan Nastic said.

Stanford will try to take the next step Sunday when it faces No. 2 seed Kansas (25-9), which held off Eastern Kentucky 80-69.

“We’re not satisfied,” junior guard Anthony Brown said. “(We’re) 40 minutes away from the Sweet 16.”

Dawkins, who played in three NCAA tournaments at Duke, then made 11 trips as an assistant coach at his alma mater, needed the Cardinal to earn a spot in the 68-team field in order to keep his job.

But there was no exhale from Dawkins, either. He has kept his attention on the next step and was thrilled for his players.

“This team will always have a place in my heart for what we are accomplishing,” he said. “It is the first chance for me as a head coach to be in the tournament, and so I will always remember the kids who got us there and got me there.

“You know, we still have games to play.”

That will happen because they did enough to turn back a Lobos team that had won 15 of its previous 17 games, including a third straight Mountain West tournament title.

Chasson Randle scored 23 points and Stanford’s defense shackled two of New Mexico’s most potent offensive weapons, limiting Kendall Williams and Alex Kirk to a combined six points on 1-for-12 shooting.

But with 10 minutes left, the Lobos pulled even when freshman guard Cullen Neal — a one-time Saint Mary’s College signee — scored on a drive to make it 45-all. He missed the ensuing free throw, but momentum seemed to have shifted.

“Just keep playing,” Nastic said of the Cardinal’s approach. “It’s not about the score, it’s about how we’re playing.”

And Stanford played better over the final 10 minutes.

The Cardinal ran off seven straight points, sparked by a 3-pointer from Randle with 8:56 left.

“We just took that play and carried it as momentum throughout the rest of the game,” Randle said.

“Chasson played great,” Huestis said. “I’m super-proud of him.”

Nastic added to the lead with a shot from the lane over New Mexico star Cameron Bairstow, who scored 24 points. Then Huestis converted a drive and it was 52-45.

Stanford’s lead was just 54-52 when senior walk-on Robbie Lemons made two foul shots with 23.8 seconds left. Randle then made two free throws after being fouled by Hugh Greenwood with 7.3 seconds left, but Randle was called for a technical foul on the play when his elbow connected with Greenwood.

Williams, shooting the free throws, made just one of two, ending the Lobos’ last comeback try.

Stanford scored on nine of its first 12 possessions to forge its 20-4 lead.

The Cardinal set the tone with defense, according to senior Dwight Powell, who helped hold 7-footer Kirk without a field goal. Brown guarded one-time Southern California AAU teammate Williams, who entered the game averaging 16.4 points but shot 1 for 9.

Said Powell, “The fact that we were holding them down early gave us a lot of confidence.”

Follow Jeff Faraudo on Twitter at twitter.com/JeffFaraudo.