"I've let down a lot of people, that's the bottom line," Sanford said at a news conference. "I have been unfaithful to my wife."
Watch video of Sanford's press conference here.
Mystery has surrounded the governor since late last week, when reporters began questioning an unexplained absence and aides struggled to verify his schedule.
Sanford, a 49-year-old father of four, told reporters the woman involved was a "dear, dear friend" he'd known about eight years. Their relationship turned romantic a year ago while he was on an economic development trip to Argentina.
Sanford said he spent "the last five days of my life crying in Argentina" and that the affair is now over.
"It started as I guess many of these things do, a casual e-mail back and forth. Here recently over the last year, it developed as something much more than that," Sanford said.
"As a consequence I hurt her, my wife Jenny, my boys ... I hurt a lot a lot of different folks," he added.
The governor said his wife has known about the affair for the last five months. His family was not present at the news conference.
In 2006, Sanford won re-election to a second, and final, four-year term as South Carolina's governor. He has been considered a possible candidate for a 2012 presidential run and had assumed the leadership of the Republican Governors Association.
The governor did not say whether he planned to leave office during Wednesday's news conference.
The Republican Governors Association announced today that Mississippi Gov. Haley Barbour will assume the duties of RGA Chairman effective immediately.
"While this news is deeply disappointing, I also know it's important to remain focused on the future and Governor Sanford's resignation allows him and us to do just that," Barbour said in the statement.
Addressing the original statement by aides that the governor was hiking, Sanford said he had considered hiking on the Appalachian Trail, "but I said 'no' I wanted to do something exotic," adding that Buenos Aires is "a great city," according to Columbia, S.C.'s The State newspaper, which spoke to the governor at the Atlanta airport upon his arrival back in the U.S.
When asked why his staff said he was on the Appalachian Trail, Sanford replied, "I don't know."
In a statement released after his 2 p.m. ET press conference, Sanford apologized for misleading his staff.
"I apologize to my staff," Sanford said, according to Politico. "I misled them about my whereabouts, and as a result the people of South Carolina believed something that wasn't true."
When news first broke about his mysterious disappearance, first lady Jenny Sanford told The Associated Press she did not know where her husband had gone for the Father's Day weekend.
The governor has a reputation for being a loner with a political independence streak that has included defying GOP leadership directives during three U.S. House terms. He caught national attention in recent months for attempting to reject federal stimulus funds for schools in his state.
Sanford's admission came a day after another prominent Republican, Sen. John Ensign of Nevada, apologized to his GOP Senate colleagues after revealing last week that he had an affair with a campaign staffer and was resigning from the GOP leadership.