"I am undergoing treatment and am more than optimistic about a satisfactory outcome, as indeed is the medical team," he told the Press Association.
Hurt, who starred as the War Doctor in Doctor Who in 2013, added he would continue with his professional work.
"I am continuing to focus on my professional commitments and will shortly be recording Jeffrey Bernard Is Unwell (one of life's small ironies!) for BBC Radio 4," he said.
The actor said wanted to announce his diagnosis to the press because he had "always been open about the way in which I conduct my life and in that spirit I would like to make a statement".
The prolific actor is due to be seen on the small screen in November in new Sky Atlantic drama The Last Panthers, opposite Samantha Morton.
He also has roles in some seven other projects, according to IMDB, including the upcoming Tarzan film, due for release next year.
Sir John was seen last year in the Dwayne Johnson film Hercules, and also appeared as The War Doctor in the iconic Day of the Doctor episode, for the show's 50th anniversary in 2013.
Among his other best-known roles include 1978's Midnight Express, for which he was also Oscar nominated and the 1975 TV series The Naked Civil Servant, which earned him a Bafta TV award.
He was also Bafta nominated for his role in Ridley Scott's Alien - the film which famously saw the titular creature burst out of the actor's stomach and has often been described as one of cinema's most memorable moments.
But many consider Sir John's performance as the deformed Joseph Merrick in The Elephant Man as his greatest role.
He was knighted earlier this year for his services to drama...