It had been building for months in Mr Major's brooding mind, but the final decision was taken "relatively recently", according to Brian Mawhinney, Secretary of State for Transport, who will help to run his campaign.
One of Westminster's best- kept secrets had been known only to a hand- picked few: Dr Mawhinney, a trusted friend of Mr Major and a near neighbour with his Peterborough constituency; Lord Cranborne,Leader of the House of Lords and an ardent Unionist, who will run the campaign; and Sir Norman Fowler, the former Cabinet minister who was on the road with Mr Major during his successful 1992 general election campaign.
Dr Mawhinney said that Mr Major had been dogged by the leadership issue for three years. He was exasperated when it overshadowed his high-powered visit to Japan in September 1993 - when he made his "barmy army" outburst. But the tension had intensified in recent weeks.
The humiliating meeting with the "Fresh Start" group of Tory MPs may have been the defining moment for Mr Major. He was treated to a rude display of disrespect by Tory Euro-sceptics, some of whom were relative newcomers to Parliament - from the 1992 intake. His authority was held up to ridicule after the meeting; it gave the impression of a Prime Minister who was the captive of his troublesome Euro-sceptic wing.
"He was annoyed that they said that they had double the number needed for a challenge for the leadership," said one of Mr Major's campaign team. "He has decided to put that to the test."
The crisis of confidence in his leadership was deepened by the intervention of Baroness Thatcher publicising her memoirs, with a sustained three-day assault on his leadership. Professing loyalty to Mr Major, she questioned his Tory credentials, telling him he was losing her bequest because he was not Conservative enough.
Confirmation that he was right to offer himself up for a challenge came last weekend when the leadership issue continued to follow him to Halifax, Nova Scotia, for the G7 summit. Tony Blair hit the bullseye on Monday when he said the leadership issue was now damaging not only Mr Major, but Britain on the international stage.
The Prime Minister secretly had come to the same conclusion before he left for the G7.
Robert Hughes, the MP for Harrow West and a former whip who lost his job after admitting a love affair with a constituent, was told by the Prime Minister on Tuesday.
He had gone to see Mr Major about another matter, when he revealed he had decided that he could not go on facing speculation about his leadership. He had decided to stand and fight. Mr Hughes was from the same local government background as Mr Major, and one of his most trusted supporters. He was a member of the Major leadership election team in 1990 which ran its operation from the home of Alan Duncan in Gayfere Street, a stone's throw from the Commons.
It was just like old times. Mr Major was pulling together the campaign team which saw him through to victory last time against Michael Heseltine. He was calling them all back in, including Michael Howard, the Home Secretary, and Graham Bright, his former Parliamentary Private Secretary. Ian Lang, Secretary of State for Scotland and a former writer for the satirical programme, That Was The Week That Was, was brought in to handle the press.
Other Cabinet ministers were individually told of the Prime Minister's decision yesterday. By the end of the day, not only had the telephones been wired up in the campaign house but his supporters said they would have 100 names on Mr Major's campaign team by the end of today. Members of the campaign team were already working through lists of Tory MPs whose support they need for victory.
Despite the widespread insistence that a Major challenger may not materialise by next Thursday's cut-off date, the Major camp has left nothing to chance. MPs will be repeatedly canvassed to ensure that Mr Major does not suffer the problem faced by Margaret Thatcher - complacency and lies. With all the plans in place, the Prime Minister's team informed Sir Marcus Fox, chairman of the 1922 backbench committee. He was told late in the day to minimise the risk of a leak.
Sir Marcus then sent word to fellow executive members, already assembled for their weekly meeting, to come to Mr Major's Commons office.
Sir Geoffrey Johnson-Smith, a vice-chairman of the committee, said Mr Major gave a short statement and then handed over an envelope containing a written copy. "It came out of the blue to us," Sir Geoffrey said.
He described the Prime Minister as "very cool, calm, quiet. There was no hint of rancour at all". Executive members were so stunned that the news was received with complete silence.
Sir Marcus then told the full meeting of the 1922 Committee of Mr Major's resignation at 5pm. Executive members immediately pledged to sign Mr Major's nomination papers.
Sir Nicholas Bonsor, a senior Conservative and one of the leaders of a "stop Heseltine" group of right-wing Euro-sceptics, said: "We were very surprised. It was a very well-kept secret. It wasn't leaked at all.
"He took the view that the damage to the party between now and November and the continuing speculation ... had to be cut off at source."
One John Major supporter said: "There are 100 weeks between now and the next election. We were not going to spend 20 of them on all this rubbish."