The former Leeds United player, 24, who won the club's player of the year and players' players accolade at the end of last season, had been in discussions over a new deal.
But he has now elected to leave when his contract runs out at the end of this month and will join the Red Imps.
A number of clubs had been linked with O'Connor, including Sheffield Wednesday.
On heading to Lincoln, who he will officially join on July 1, O'Connor said: "I wanted to pick somewhere I could develop and have the opportunity to play another 40 plus games a season, as I have over the past few years.
"My next career move needed to be right football-wise. I wanted to step up to League One and it’s clear there is a structure in place here to allow me to kick on."
He is the club's first signing since former Republic of Ireland winger Mark Kennedy was named as manager.
He said: "Paudie was our number-one target for his position and we are delighted to be able to announce him as our first signing of the summer.
"He has been in great demand and we have worked really hard to convince him that this is the right move for his career.
"Paudie is more than just a fantastic defender. He is also a leader and will have a massive role to play in what we want to achieve moving forward, on and off the pitch."
City, who have brought in eight new signings already ahead of the 2022-23 campaign, have also offered fresh terms to Charles Vernam and Elliot Watt, whose deals also expire shortly.