Last summer McCain said he had been diagnosed with an aggressive glioblastoma, "and the prognosis was serious," his family said in a statement.
"In the year since, John has surpassed expectations for his survival. But the progress of disease and the inexorable advance of age render their verdict," the McCain family said. "With his usual strength of will, he has now chosen to discontinue medical treatment. Our family is immensely grateful for the support and kindness of all his caregivers over the last year, and for the continuing outpouring of concern and affection from John’s many friends and associates, and the many thousands of people who are keeping him in their prayers. God bless and thank you all."
McCain's wife, Cindy, and daughter, Meghan, thanked the teams who took care of him and members of the public who have supported their family.
One of McCain's closest friends in the Senate, Sen. Lindsey Graham of South Carolina, said in a statement that Cindy McCain and their family were providing "abiding love, care, and dedication" for John McCain.
"Cindy remains steadfast and is traveling every step of the way on this difficult journey with John. The love provided by Meghan and the McCain children to their father has been comforting to witness. The entire McCain clan is doing exactly what the McCains have done through generations — rise to the meet the challenge. In addition, John’s deeply loyal staff and devoted friends are pouring their hearts out and doing everything they can to make this burden bearable. John’s medical care providers represent the best of their profession," Graham said in a statement.
Congressional leaders, members of Congress and lawmakers who worked closely with McCain also posted messages of support on social media.
ABC News' Ali Rogin contributed to this report.