Ashfield, 60, confirmed the news in a statement, saying he himself recommended to the prime minister that a temporary replacement be appointed during his absence from the Conservative cabinet.
"This weekend I suffered a heart attack while at home in Fredericton," Ashfield said.
"Thanks to prompt medical attention I am now in stable condition and awaiting bypass surgery. While I am assured of a full and complete recovery, my doctors have advised me that I will require several weeks of rest and recuperation."
The former minister in the New Brunswick government of Bernard Lord added that, "while I am focused on my recovery, I look forward to returning to Ottawa and getting back to work."
Shea, of Prince Edward Island, returns temporarily to the Fisheries portfolio she held before Ashfield replaced her after the 2011 election.
She will also continue to serve as minister of national revenue.