It wasn’t until she looked at the scoreboard that Regan Smith realized what she had done. At the world swimming championships in Budapest, Hungary, the Lakeville teen blazed through the semifinals of the women’s 200-meter backstroke in 2 minutes, 7.19 seconds — breaking the world junior record.

Smith, 15, put her hand to her mouth as tears welled in her eyes. After swimming a personal-best time in Friday’s morning preliminaries, she went even faster in the semis to earn a place in Saturday’s finals. Smith’s time was the fifth-fastest among the eight finalists, who include U.S. teammate Kathleen Baker, top qualifier Emily Seebohm of Australia and Olympic silver medalist Katinka Hosszu of Hungary.

The youngest member of the U.S. team, Smith dropped 1.36 seconds off her previous best time in the event. Her semifinal time broke the world junior record of 2:07.43 set by Russia’s Daria Ustinova in 2015.

In a phone call after the semifinals, Smith told her father, Paul, that she was “a bit surprised’’ to have gone so fast. “It felt great,’’ she said. “The speed was pretty easy. It didn’t feel that fast. The world junior record was a pleasant surprise.’’

Smith, a member of Apple Valley’s Riptide Swim Team, clocked the fourth-best time in the preliminary heats (2:08.13). In the first of two semifinals, she had the lane next to Hosszu — a multiple Olympic medalist and the home-country favorite — and held the lead late in the race before Ustinova passed her in the final meters. 

The top three qualifiers all came out of the second semifinal heat. Seebohm (2:05.81), Canada’s Kylie Masse (2:05.97) and Baker (2:06.66) dominated the race and enter the finals as the favorites.

The top eight swimmers made Saturday's final, which will be televised on NBC (1 p.m.).