Iain Banks, 59, posted a message on his official website saying his next novel The Quarry, due to be published later this year, would be his last.
The writer’s novels include The Wasp Factory, The Crow Road, Complicity and the Culture series.
The statement said Iain Banks’ health problems came to light when he saw his doctor, suffering from a sore back.
Iain Banks was diagnosed with jaundice, before further tests established the full extent of his illness.
The writer said in the same statement that he had asked his partner Adele to marry him and was now on a short honeymoon.
Iain Banks, who lives in North Queensferry, Fife, said he had cancelled all future public engagements.
“The bottom line now, I’m afraid, is that as a late-stage gall bladder cancer patient, I’m expected to live for ‘several months’ and it’s extremely unlikely I’ll live beyond a year.
“So it looks like my latest novel, The Quarry, will be my last.”
The author said the disease had spread to both lobes of his liver, and possibly his pancreas and lymph nodes.
Iain Banks added that there was little chance of surgeons being able to remove the tumors because of how far they had spread.
He has asked his publishers to bring forward the publication of his new book to “give me a better chance of being around when it hits the shelves.”
Born in Fife, Iain Menzies Banks studied at Stirling University before publishing his first novel, The Wasp Factory, in 1984.
He has alternated between mainstream and science fiction novels, which he wrote under the name Iain M. Banks.
In 2008, Iain Banks was named one of the 50 greatest British writers since 1945 in a list compiled by The Times.
News of his illness was described as “terribly sad” by First Minister Alex Salmond.
A website, called Banksophilia, has been created for friends and fans to leave messages for Iain Banks.
Edinburgh Book Festival tweeted: “Such sad news. Iain Banks our thoughts are with you and your loved ones.”
The Scottish Book Trust added: “We’re all shocked and saddened by Iain Banks’ news. We send our best wishes to him, his family and friends.”
Quincy Jones, the celebrated musician and producer who worked with Michael Jackson, Frank Sinatra, Ray…
Misleading allegations, rumours and outright lies about voting and fraud are flooding online spaces in…
At least 158 people have died in Spain's worst flooding disaster in generations. On October…
Google has been fined two undecillion (a two followed by 36 zeroes) roubles by a…
Embarking on a home remodel is an exciting journey, promising enhanced comfort, increased property value,…
The US presidential candidates continued to campaign across key swing states on October 20. Footage…