Kevin Davies scored his first goal for Preston as they beat Oldham to move into the League One play-off places.
The 36-year-old summer signing drove a penalty just inside the post after he had been fouled by James Wesolowski.
Stuart Beavon had given North End the lead when he unknowingly flicked in Joel Byrom's free-kick and Scott Laird later missed a chance for a third.
Oldham dominated the closing stages and James Tarkowski powerfully headed in a corner but they could not grab a point.
Tarkowski earlier had a header saved by Preston keeper Declan Rudd while the follow-up effort from Danny Philliskirk was cleared off the line.
North End are now sixth in the table, unbeaten in their six matches, while the Latics are four points behind in 14th place.
VIEWS FROM THE DRESSING ROOM
Preston North End manager Simon Grayson told BBC Radio Lancashire:
"We knew that Oldham have got some quality and were going to be a test for us.
"Should we have won the game? Possibly not because they had some good chances and kept possession well.
"But we had to do whatever was required to win the game. That meant putting bodies on the line. We have and will play better than that and not win games."
Oldham Athletic manager Lee Johnson told BBC Radio Manchester:
"It was the same old story - we dominated the game, but we were 2-0 down and they hadn't done anything.
"We had something like 18 chances away at a team like Preston, which shows where we are, but we're sat here as brave losers.
"That's a tag we have to shake off very quickly because we need to win some games."