Updated

Drew Brees made a little more history for the New Orleans Saints and kept the mistake-prone Detroit Lions struggling.

Brees passed for 342 yards and three touchdowns, and the Saints won their fourth straight, 31-17 on Sunday night.

The performance gave Brees 4,031 yards this season, making him the first quarterback in NFL history to eclipse the 4,000-yard mark in the first 12 games.

"We were able to spread the ball around and come up with some big plays," Brees said. "I hope our hopes and aspirations are bigger than setting records."

His touchdown passes went for 67 yards to Robert Meachem, 20 yards to Lance Moore and 6 yards to Darren Sproles. He also connected eight times with tight end Jimmy Graham for 89 yards as the Saints (9-3) improved to 6-0 at home while taking a two-game lead over Atlanta in the NFC South.

"He's a stud, a young raw talent but a guy who's figuring it out quickly," Brees said of Graham, who became the first Saints tight end to have 1,000 yards receiving in a season. "I love most his heart and desire."

Matthew Stafford passed for 408 yards and one touchdown for the Lions (7-5), who have lost five of their last seven, but remain in playoff contention.

The Lions hurt themselves with 11 penalties for 107 yards, including three offensive pass interference penalties and a personal foul on tight end Brandon Pettigrew for shoving an official who was trying to get between him and Saints safety Roman Harper after the whistle.

"We lost to the Saints, but we beat ourselves today. Our offense continued to get derailed by penalties," Lions coach Jim Schwartz said. "We need to act accordingly. We need to be a team that doesn't beat ourselves. We have talent, we have good schemes, good coaching. We cannot afford to be selfish and put the team at risk of taking points off the board and there was way too much of that today."

The mistakes made it impossible for the Lions to keep pace with the league's No. 1 offense, and Detroit missed a chance to take a one-game lead over Chicago and Atlanta in the NFC wild-card race.

Mark Ingram scored New Orleans' first touchdown on a 14-yard run. The Saints then built a 24-7 halftime lead on the touchdowns to Meachem and Moore before Detroit showed signs of mounting a comeback in the third quarter.

Jason Hanson's 31-yard field goal made it 24-10. The Lions pulled within one score on Maurice Morris' 9-yard touchdown reception from Stafford, capping a nine-play, 88-yard drive.

Hanson lined up for 55-yarder early in the fourth quarter that could have pulled the Lions even closer, but it missed wide left.

The Saints pulled away again early in the fourth quarter on Sproles' TD, which capped a seven-play, 55-yard drive on which Brees found Graham four times for 46 yards.

Graham said he was in man-to-man coverage, "and Drew laid a couple in there for me."

"He's a surgeon out there and makes me look good," Graham added. "When your quarterback has confidence in you, it raises you to a new level."

Although the Lions were without Ndamukong Suh because of his two-game suspension, and also without injured defensive backs Chris Houston (left knee) and Louis Delmas (left knee), Schwartz said that was no excuse for several defensive lapses, particularly in the first half.

"We played poorly on defense. We never gave ourselves a chance," Schwartz said. "We didn't get the job done in coverage, we didn't get the job done rushing the passer."

Still, Detroit got more pressure on Brees than the Saints' recent opponents, sacking him twice. Brees had not been sacked in three previous games.

Stafford completed 31 of 44 passes, but was sacked three times and intercepted by Tracy Porter.

Nate Burleson had five catches for 93 yards, while Calvin Johnson had six catches for 69 yards.

Meachem caught three passes for 119 yards.

After Meachem's TD made it 17-0, the Lions responded with an 80-yard scoring drive on which Stafford completed all six of his passes. Kevin Smith's 2-yard TD run made it 17-7.

Moore's score with 22 seconds left in the first half increased the lead to 24-7, but the Lions had a chance to get some points in the final seconds after Titus Young beat Saints defensive back Patrick Robinson deep down the left sideline for a 52-yard gain to the Saints 24.

Robinson saved a touchdown by pushing Young out of bounds, then made amends for his earlier mistake in coverage by coming off the end to block Hanson's field-goal attempt as time expired in the half.

The first quarter was more of a defensive struggle, with the only scoring coming on John Kasay's 39-yard field goal that gave New Orleans a 3-0 lead.

His kick capped a methodical 13-play, 41-yard drive during which the Saints converted three third downs.