Lochte touched first in 51.93 seconds, second-fastest in the world this year. Phelps was second in 52.13, fourth-quickest in the world. He lowered his time of 52.84 from the morning heats.
Lochte beat him to the first turn. "That may have been the worst turn that I have ever done in my entire life," Phelps said later.
It didn't matter to the sellout crowd of 1,200 at the Arena Grand Prix in Mesa, Ariz., who loudly cheered Phelps. "Everyone is happy that he's back in the water," Lochte said. "It's good for the sport."
Lochte said he and Phelps hadn't seen each other since London, but they picked up where they left off, joking with each other before trying to beat each other.
"I'm going to do everything I can to try to get my hand on the wall before him in every single race; I don't care what it is, and it's the same for him," Phelps said. "We bring the best out of one another."
Natalie Coughlin, who took her own extended break after the 2008 Beijing Olympics, said of Phelps: "When he started talking about coming back, I thought it was so good for him. He's so young and he's enjoying it, so why not?"
Coughlin won a relay bronze medal in London, and at 31 is making a push toward the 2016 Rio Games.
Feeling No PressurePhelps, who turns 29 in June, owns 18 Olympic gold medals in middle and longer distance races. But he is going to try sprinting on Friday. Phelps will compete in the 50-meter freestyle, except he plans to swim his morning heat using a butterfly stroke.
It's allowed under the rules, and Phelps is doing it to work on his stroke under race conditions, something he hadn't experienced until beginning his comeback this week after a 20-month retirement.
"If I can get into the rhythm of my normal stroke again in the 50, I'll be pretty happy," he said.
Also competing in the 50 free are former Olympic gold medalist Anthony Ervin, Nathan Adrian and Michael Andrew, a 15-year-old from Lawrence, Kan., who has already broken over 30 national age-group records.
Phelps's times in the 100-meter butterfly were easily good enough to surpass the qualifying standard of 54.79 for the U.S. national championships in August. That meet will decide the team for next year's world and Pan Pacific championships.
But he's not rushing to commit to anything.
"I'm not saying yes or no yet," he said. "I'm not putting any pressure on myself to say I'm doing this or doing that in the future. I'm just enjoying myself right now."