ARLINGTON, Texas -- Yu Darvish came oh, so close again.
"This is the second time I experienced this, but if I keep pitching like this, someday I'll get it," Darvish said through his translator. "Someday, I'll just keep doing what I'm doing and I'll probably have another record of almost a no-hitter."
Rookie second baseman Rougned Odor, positioned in shallow right field, made a diving attempt at Ortiz's hit but the ball was out of his reach. If the Rangers had not shifted their infield toward the right side of the diamond -- a standard practice against the pull-happy Ortiz -- it probably would have been a routine grounder to second.
Darvish lost a perfect-game bid with two outs in the ninth inning last season against Houston. This time, he bent his knees and put his glove on his hips after the base hit. Texas manager Ron Washington then made a slow walk to the mound, with the 45,392 in attendance cheering and chanting "Yuuuuuu!"
Darvish (3-1) struck out 12 and walked two while throwing 126 pitches.
The 20-year-old Odor, playing his second major league game, and Ortiz were also involved in the play that ended Darvish's try for a perfect game.
Darvish struck out eight of the first 11 batters he faced and retired 20 in a row until Ortiz hit a high popup to right field with two outs in the seventh.
Odor was also shifted into shallow right then and drifted back for the ball while right fielder Alex Rios came in before suddenly stopping. Odor lunged with his glove extended above his head but the ball dropped between them.
"As soon as he hit it, I thought it was going to be a hit," Darvish said. "Obviously I was a little bit disappointed, but I was already ready to give up a hit, so it didn't really matter."
An error was charged to Rios after official scorer Steve Weller looked at replays and conferred with several others because of the significance of the play.
"I should have taken control of that ball," Rios said. "We were camped under the ball, so it can be called an error."
Odor said crowd noise was a factor. "I thought I heard a call for the ball and pulled off," he said.
Weller, in his 20th season as a scorer, told a pool reporter after the game that it was a judgment call and "I felt like the second baseman or right fielder under normal effort could've clearly caught the ball."
Asked if he had spoken to Darvish, Rios said, "I just told him that I should have caught it. That's the only thing I said."
Darvish, who was coming off the mound in case he needed to back up a base, crouched down when the ball hit the ground. Former Rangers catcher Mike Napoli then drew a walk before Grady Sizemore's inning-ending fly out.
Darvish walked another batter in the eighth but went into the ninth looking for the first no-hitter in the majors this season. Dustin Pedroia grounded out and Shane Victorino struck out before Ortiz stepped to the plate.
"I think somebody must be mad at him,'' was Rangers shortstop Elvis Andrus' take on the near-miss. "He just needs to keep doing the same thing.''
Darvish was within one out of a perfect game during his first start of 2013 in Houston when Marwin Gonzalez singled through the pitcher's legs. Darvish then lost a no-hit bid with one out in the eighth against the Astros last August.
Four weeks ago, Darvish was perfect through five innings at home against the Astros before a leadoff single in the sixth. He threw eight scoreless innings that night in a game the Rangers won 1-0 in 12 innings.
Andrus had four hits and scored three times for the Rangers in this one.
He was back in his normal No. 2 spot in the batting order for the first time in six games. Washington had moved his shortstop down in the lineup after a 2-for-34 slide that dropped him to a season-low .217, but moved him back to split up the five left-handers in his lineup against Clay Buchholz (2-3).
Buchholz allowed six runs and 10 hits over 4? innings. He struck out three and walked two while throwing 96 pitches.
It was Darvish's 21st career game with at least 10 strikeouts, the most in the majors since his debut in 2012. Detroit's Max Scherzer is next on the list with 14 in that span.
Darvish was winless in his previous nine home starts, despite a 2.83 ERA in those games. He had not won at home since last Aug. 1 against Arizona.
Texas went ahead to stay when Andrus had a one-out single in the first and scored on a double by Adrian Beltre.
The last no-hitter for the Rangers was Kenny Rogers' perfect game against the California Angels on July 28, 1994. ... Boston last went without a hit on April 22, 1993, against Seattle's Chris Bosio. ... Andrus had the first four-hit game by a Texas player this season. ... Odor, the youngest player to appear in a major league game this season, got his first hit with a single in the fourth.
Information from The Associated Press and ESPNDallas.com contributor Randy Jennings was used in this report.