The poster on Oldham Athletic's dressing room instructed the players not to give away their shirts "due to a severe shortage" of first-team kit but it is fair to say the club will forgive Matt Smith for having the temerity, 10 minutes or so after the final whistle, to throw his to those supporters in the Rochdale Road End who had made it clear they did not want to go home.

It was the last touch of the match, in the fifth minute of stoppage time, when Smith emerged as the hero, just as he had in the previous round against Liverpool. The public announcer had already named Lee Croft as the man of the match and wished everyone a safe journey home. The first supporters were heading away into the red-bricked terraces that surround this little old ground – but the team fighting relegation to the fourth division were determined there would be one final twist.

They had subjected Everton to a ferocious aerial bombardment once the clock turned past 90 minutes, with their own goalkeeper Dean Bouzanis virtually encamped in the opposition penalty area for the late succession of corners.

Smith, standing 6ft 6in and absolutely determined to make a nuisance of himself, was a formidable target. Jonathan Grounds knew who to aim for and it was the tallest player on the pitch who applied the decisive touch through the scrum. The reward is a replay at Goodison Park and, as every Evertonian should remember, the last time they played there, in 2008, the League One side won 1-0.

"Financially, what that means to the club is the most important thing," Oldham's caretaker manager, Tony Philliskirk, said. "The dream result was a draw. I looked round after the goal and the directors were jumping up and down more than anyone. It eases things for us."

Yet, money aside, there was some old-fashioned FA Cup romance here, too. Smith was playing for Littleton in the Midlands Combination two years ago. As for Philliskirk, he had taken charge of Oldham's youth team in the morning for a 1-1 draw with Rochdale. "It was one man and his dog," he said.

At times, as Philliskirk conceded, Everton had "dominated, controlled the ball, looked very comfortable." Yet Oldham played with great perseverance and commitment. The pitch was threadbare, the perimeter boards advertised Clayton Park pies and the pre-match music had included Cannon and Ball's Boys in Blue. Everything was in place for a classic FA Cup night and it quickly became apparent Oldham scented another upset when they broke from defence and Jordan Obita, a 19-year-old on loan from Reading, turned in Lee Croft's misdirected shot for the opening goal. Even after Victor Anichebe had taken advantage of a mistake by Jean-Yves M'voto to rifle a 25th-minute equaliser past Bouzanis, there were reminders why the swagmen outside Boundary Park had been selling "giant-killers" scarves and flags. Within a minute, Obita's deflected shot had come back off Tim Howard's left-hand post. Oldham never once looked overawed.

They did, however, lose their way for a good half an hour after Phil Jagielka had headed in the substitute Kevin Mirallas's corner three minutes into the second half. They were soft goals to concede and the Premier League side ought to have had too much knowhow to be caught in that position. "With a minute to go, you think you've got through without playing great," David Moyes, Everton's manager, said. "But Oldham more than deserved their replay, so fair play."

Philliskirk, filling the void left by Paul Dickov's departure, had changed the team's system to 4-2-4 and instructed his team to "go as high as you like". The crosses into the penalty area created havoc but the chance appeared to be gone when Howard saved Smith's shot and then kept out another substitute, Robbie Simpson, with an even better save.

Smith was making his comeback after he damaged his shoulder while scoring two of the three goals that had knocked out Liverpool. Near the end the electronic board flashed up four minutes of added time – and the final act was officially timed at 94min 9sec.