Updated

Rory McIlroy had struggled enough to lose the world's top ranking, prompting his caddie to suggest playing the Texas Open to get some more preparation in before the Masters.

McIlroy heeded the advice and played his best golf in what has so far been a dreadful start to the season.

"I feel like my game's in really good shape going into next week," he said after a final-round 66 on Sunday. "A round like that gives me a nice bit of confidence."

Trouble is he ran into Martin Laird on one of the finest days of the Scotsman's career.

McIlroy and Laird showed an impeccable sense of timing Sunday during a back-nine duel in San Antonio — especially considering it was the final competitive round both will play prior to the first major of the season.

McIlroy knew he was headed to Augusta National before arriving in San Antonio, while Laird didn't.

Laird finally found what he was looking for after six months on the driving range, shooting a course-record 63 in the final round — a bogey-free effort that put him two shots clear of the resurgent McIlroy at 14 under.

"I came in here quietly confident, even though my record this year has been poor, to say the least," Laird said. "But golf's a funny game ... doesn't matter what you did two weeks ago. It turns around pretty quickly."

Laird, who began the day four shots behind overnight leader Billy Horschel, hardly resembled the same golfer who began the week 161st on the money list. He punctuated the convincing effort with birdies on the final three holes, staring down McIlroy and an experienced group hot on his tail.

Along the way, he became the first PGA Tour player to earn a trip to the Masters with a win in the last week before the tournament since Johnson Wagner won the Houston Open in 2008.

The win was Laird's third on tour and his first since the Arnold Palmer Invitational in 2011.

McIlroy, who has dropped to No. 2 in the world ranking, began the day at 6 under before posting his best finish of the year.

The day was exactly the kind of competitive final round McIlroy envisioned when he signed up for the Texas Open late last week in advance of the first major of the year next week.

McIlroy was anything but consistent from the tee and on the greens throughout the week. He finished 48th in fairways hit — hitting only 7 of 14 on Sunday — and was 63rd in taking 118 putts for the four rounds.

However, he managed to score even when doing just that seemed unlikely. McIlroy was tied for first in greens in regulation, showing the kind of shot making he'll need if he's to contend at Augusta National.

"I thought if I got to 12 under today that might have been good enough, but Martin just played too good and holed so many putts. It was hard to keep up."

While McIlroy struggled at times on the greens, Laird had no such problems — needing only 108 putts for the tournament. That included an astounding 22-putt effort Sunday, one that was aided by a stunning up-and-down for birdie out of the fairway bunker and off the fringe on No. 17.

He entered the week having missed four of eight cuts this year following a swing change last September, including a missed cut at last week's Houston Open. However, he shot a second-round 65 in that event after a four-hour range session — providing plenty of confidence that his game was finally starting to come together.

Laird birdied five of his first eight holes to immediately jump into contention. His 7-foot birdie putt on No. 8 — one of only 22 putts in the round — put him into a tie with Horschel at 10 under.

He capped the win with a 15-foot birdie putt on the par-5 18th.

Jim Furyk eagled the par-5 18th from 104 yards to jump into a third-place tie with Horschel and Charley Hoffman. The former U.S. Open champion had only four holes of practice on the Greg Norman-designed Course at TPC on Wednesday before rain washed him out, but he posted a 69 to close out a steady week.

Horschel, who led after the second and third rounds, was unable to match the low rounds of his competitors and finished with a 1-under 71. The Florida native, who was second at last week's Houston Open and was borderline defiant earlier in the week about his chances of competing against former major winners, was seeking his first PGA Tour win.

"Everyone's going to have butterflies," Horschel said. "I don't care if it's Tiger Woods or Joe Schmo at the golf course; you're going to have butterflies, and you have to learn how to deal with it."

McIlroy closed to within a shot of Laird when he sank a 13-foot birdie putt on the 204-yard par-3 16th to reach 11 under, but it was Laird who closed like the two-time major winner rather than someone just trying to play in next week's major.

While McIlroy's primary focus throughout the week was on preparing for Augusta National, Laird couldn't have imagined when the week began that he would join the former world No. 1 next week.

Laird earned this third straight trip to the Masters with his win, which he closed out with three straight birdies. That included the surprising up-and-down on No. 17 and finishing with a 15-foot putt for birdie on 18 — clinching a share of the course record, which was set in last year's opening round by Matt Every.

Laird played at Augusta National the last two years following his win at the Arnold Palmer Invitational in 2011, finishing 20th two years ago and 57th last year.

Well-known name or not, Laird overcame some of the world's best Sunday.

"I know how good Rory is, but it doesn't matter if it's Rory or Jim or Billy, if someone's behind me making birdies like they were, I know I've got to keep making birdies," Laird said. "That was a pretty strong leaderboard at the top there."