"The Senator's doctors say he is recovering from his surgery 'amazingly well' and his underlying health is excellent," the hospital said.
McCain's family, fellow members of Congress, statesmen and supporters immediately took to Twitter to express shock, prayers and many appeals to his tough reputation.
His daughter, Meghan McCain, tweeted a statement saying "he is the toughest person I know. . . . Cancer may afflict him in many ways: But it will not make him surrender. Nothing ever has."
Former President Barack Obama called him "an American hero and one off the bravest fighters I've known," while Hillary Clinton said McCain was "as tough as they come".
About 20,000 people in the US each year are diagnosed with a glioblastoma, a particularly aggressive type of brain tumour.
The American Cancer Society puts the five-year survival rate for patients over 55 at about 4 per cent.The tumour digs tentacle-like roots into normal brain tissue.
Patients fare best when surgeons can cut out all the visible tumour, which happened with McCain's tumour, according to his office.
That isn't a cure; cancerous cells that aren't visible still tend to lurk, the reason McCain's doctors are considering further treatment.
It's the same type of tumour that struck McCain's close Democratic colleague in legislative battles, the late Ted Kennedy of Massachusetts.
Politicians from both sides of the aisle offered their encouragement and prayers.
"John McCain is an American hero & one of the bravest fighters I've ever known. Cancer doesn't know what it's up against. Give it hell, John," Obama tweeted.
"John McCain is as tough as they come. Thinking of John, Cindy, their wonderful children, & their whole family tonight," Clinton posted on her Twitter account.
Senator Jeff Flake, R, said he spoke with his fellow senator from Arizona and that it was a "tough diagnosis, but even tougher man".
From House Speaker Paul Ryan, R.: "SenJohnMcCain has always been a warrior. It's who he is. All of us, not as Republicans or Democrats, but as Americans, are behind him."
Other Twitter postings:
"SenJohnMcCain is an American hero. I pray for him and his family. I look forward to seeing him soon."
- Senator Marco Rubio, R.
"Thinking about a hero, my Chairman, my friend John McCain. Stay strong!"
- Senator Tim Kaine, D.
"My friend @SenJohnMcCain is a dogged ole S.O.B. Sharp as hell and tougher than a $2 steak. I look forward to catching up with him soon.
- Former Congressman John Dingell, D.
- additional reporting AP