Left-hander O'Hern, who beat Woods 3&1 in the second round in 2005 when the pair first met in the event, rolled in a 13-foot par putt on the 20th hole to seal a dramatic win.
World number one Woods, who trailed by four after seven holes, mounted a stirring fightback with three consecutive birdies from the 10th before missing a four-foot birdie putt for victory on the 19th green.
Champion in 2003 and 2004 when the event was held at La Costa Resort, Woods took the match into extra holes after powering a massive drive off the 18th tee and setting up another birdie with an approach to five feet.
"The back nine was pretty stomach-churning," O'Hern told reporters after reaching the last eight for the third time in four appearances.
"I knew he was going to make birdie on 18 and then he let me off the hook on the 19th, so things went my way.
"I forced him to make a lot of birdies, which he did. He's the number one player in the world for a reason and it was a heck of a match in the end."
NEXT OPPONENT
O'Hern's next opponent will be Swede Henrik Stenson, who came from one down after six holes to beat Australian Aaron Baddeley 4&3.
Britain's Justin Rose was the first player to reach the quarter-finals with a 3&2 win over American Charles Howell III.
Also going through to the last eight were holder Geoff Ogilvy of Australia, Canada's Stephen Ames, South Africa's Trevor Immelman, American Chad Campbell and Britain's Paul Casey.
"This is the best I've played so far this year," said U.S. Open champion Ogilvy, who won 2&1 against Sweden's Niclas Fasth
"I didn't play quite as good today but I think that's probably the nature of the weather. I played fantastic the first two days."
Ames knocked out American Stewart Cink 3&1, Immelman beat Britain's Ian Poulter 2&1, Casey overcame American Shaun Micheel two up and Campbell won a tight match with 2005 champion David Toms one up after neither player led by more than a hole.
Woods, ill-at-ease with his swing for much of the day, made a dismal start against O'Hern.
He double-bogeyed the fourth after driving into water and lost the fifth when O'Hern rolled in a birdie putt from 15 feet.
DESERT SCRUB
Woods also double-bogeyed the sixth after his tee shot ended up behind a cactus and conceded the seventh after again driving into the desert scrub and wildly over-hitting the green with his approach.
"It was a struggle," Woods said. "I just did not have control of my golf swing. I had a two-way miss going today. I just battled through it and the only thing I knew I could do was putt and just try and get on the green somehow."
The 31-year-old American began his fightback with a 16-foot birdie putt at the par-three eighth.
He followed up with a 14-footer at the 11th and rammed in a nine-footer at the 12th to trim O'Hern's lead to one and set up a pulsating finish.
Rose went five up on Howell after nine holes before holding off a late rally by his opponent with a 14-foot birdie putt at the par-three 16th.
"I've been playing nicely and felt a lot more comfortable today with my putter," Rose told reporters.
"Today was a complete contrast and really tough playing into the wind for the first seven holes. But I hit some good iron shots and made some good pars."