"The penalty is a $150 fine and 20 demerit points. Police would like to thank any member of the public who helps us keep our roads safe."
Last week O'Connor said he had no memory of driving in a way that would warrant police attention, and he repeated that when contacted by the Herald yesterday.
But he had been shown photographs of him crossing the centreline.
"I've accepted that I crossed the line and I've paid the ticket," O'Connor said.
He said he was not impaired in any way - he does not drink - nor was he attending to his son Michael, who has autism.
"No excuses. I accept it. No excuses."
Asked if he was embarrassed, O'Connor said: "It is what it is."
He could not recall receiving any demerit points before, but would be more vigilant about staying in his lane in the future. "These things are always good lessons."
The offence would probably "bemuse" political commentators, he said.
"The fact that I've pleaded guilty to 'failing to keep left' doesn't signal that I'm going to be crossing the floor anytime soon."
Failing to keep left is an infringement offence and does not result in a criminal record.
O'Connor has told the Prime Minister's office.
A spokesperson for the Prime Minister said: "The Prime Minister expects the members of the caucus and all the MPs to abide by the law."
It is not the first time an MP has been on the wrong side of the law.
Last year Transport Minister Phil Twyford was fined $500 for breaking aviation rules when he made a phone call on a plane after the aircraft doors had shut.
He offered to resign, but Prime Minister Jacinda Ardern instead stripped him of responsibility for the Civil Aviation Authority.
In 2014, National MP Gerry Brownlee was fined $2000 for breaching airport rules when he bypassed security to board a domestic flight while he was Transport Minister.
In 2010, former Act MP David Garrett resigned from Parliament in 2010 after he revealed he had used a dead baby's identity to obtain a false passport in 1984.
Labour MP Ruth Dyson resigned her ministerial portfolios after being convicted of drink driving in 2000. She returned to ministerial roles six months later.
Former Labour MP Taito Phillip Field was convicted on 11 charges of bribery and corruption in 2009 after having Thai nationals work on his properties in Samoa and New Zealand in exchange for immigration assistance.
He lost his ministerial posts when the allegations arose in 2005, and was formally expelled from the party in 2007 after saying he might run against Labour.
The Act Party expelled its former MP Donna Awatere Huata after fraud allegations arose. She was convicted in 2005 for taking $80,000 from the Pipi Foundation.
Former United Future leader and Minister Peter Dunne joked about being fined twice for speeding on the same day in 2013.
"I have been taking counselling because this is a very serious state of affairs and I'm just ashamed of the fact that you've exposed me as a serial traffic offender," Dunne said at the time.
O'Connor was the longest-serving president of the Police Association before he became the MP for Ohariu in 2017.
Prior to that he was a police officer, rising to the rank of senior sergeant.
In 1995 he became the association's president, a position he held until 2016.
He was awarded life membership of the Police Association in 2017.