Felipe Massa has announced he will retire from Formula 1 at the end of the 2016 season.
The Williams driver, a veteran of 242 grand prix starts, is out of contract at the end of this year but had previously said he was keen to stay.
Massa spoke to Williams about a renewal as well as having discussions with other teams about extending his stay in F1.
But it is believed retaining the Brazilian was not Williams's top priority and he has now decided to choose his own destiny, ending a career that has spanned 14 seasons.
Announcing his decision at a press conference at Monza, alongside deputy team principal Claire Williams, Massa said: "I'm more nervous now than all my race starts.
"After 27 years of my racing career, since I started karting and with 15 years in F1, this will be my last season in F1."
Massa was a Ferrari protege early in his career, testing for it and racing for its customer engine team Sauber in 2002 and '04-05.
He raced for Ferrari itself from 2006-13, scoring 11 wins and coming agonisingly close to winning the title in '08.
The Brazilian, who missed the final eight races of the 2009 season after suffering a skull fracture in a freak accident in Hungarian GP qualifying, joined Williams in '14.
Having been overshadowed by team-mate Fernando Alonso at the end of his Ferrari career, Massa achieved a resurgence at Williams.
"I'm so proud to have been part of this team," said Massa.
"Williams had a difficult moment and then we managed to get amazing results in the last two championships."
Claire Williams added: "This is a very sad and emotional day. For Felipe I know this was a big decision. He was so nervous.
"He is what we love at Williams, a true gentleman.
"We were so lucky he joined for 2014. We were a team in dire straights, we needed someone to come and be part of the team."
Massa is set to contest his 250th F1 race in the season finale in Abu Dhabi.
The news comes at the same venue where Massa's mentor Michael Schumacher announced his initial retirement from F1 10 years ago.
"I choose this place because 10 years ago Michael announced his retirement here," Massa said.
"The only way for me to stay [at Ferrari for 2007] was for him to stop. He chose to give me this option to stay."
Massa said he had no post-F1 plans but was open to racing elsewhere.
"I love to race, I will have time to race," he said.
"Maybe I will race in another championship and do what I love to do.
"I'm 35 and I'm retiring! I don't feel so old to retire but this is the sport."
Williams is believed to be keen on retaining Massa's current team-mate Valtteri Bottas.
Jenson Button, Felipe Nasr and Sergio Perez are also understood to be under consideration for a race drive.