The best-selling Scottish author released the statement on his website on Wednesday.
In the statement, he says: "I am officially Very Poorly".
The 59-year-old author goes on to describe how a recent bout of jaundice is "the least" of his problems, and that he has been diagnosed with advanced cancer.
"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 Quarry is due for release later this year.
He said the cancer has spread from his gall bladder to other organs, and that surgery is not an option.
"As a result, I've withdrawn from all planned public engagements and I've asked my partner Adele if she will do me the honour of becoming my widow (sorry – but we find ghoulish humour helps)," he wrote on his website.
Banks's debut novel, The Wasp Factory, was published in 1984. His 1992 novel The Crow Road was adapted into a successful TV miniseries.
He is also well-known for his speculative science fiction, which he publishes under the name Iain M Banks. In 2008, the Times named Banks as one of the 50 greatest British writers since 1945.