He had previously been expected to keep his job during the Cabinet realignment despite ongoing clashes with Dominic Cummings, Johnson's chief political strategist.
"It will be based in Number 10 and Number 11 (Downing Street) and will jointly advise the Prime Minister and the Chancellor of the Exchequer as they work to level up the economy across the United Kingdom", the spokesman said, adding that Sunak had worked closely with his predecessor on the budget due in March. When it doesn't, the government can look dysfunctional.
This is now being replaced with an integrated Number 10-Treasury team of advisers at the top of that structure.More news: Proud father Dwayne Wade remembers the moment his daughter announced her transition
That appeared to be the main sentiment in financial markets, as traders calculated that the higher spending would inevitably lead to the Bank of England having to raise interest rates more quickly than anticipated.
Javid had been due to deliver his annual budget next month.
Other big-name casualties of the reshuffle include business secretary Andrea Leadsom and attorney general Geoffrey Cox.
In his shakeup, Johnson fired and appointed ministers to key Cabinet posts. His office said Foreign Secretary Dominic Raab, Home Secretary Priti Patel, Justice Secretary Robert Buckland and Cabinet Office Minister Michael Gove were all staying.More news: Woods fades to five adrift at PGA Genesis Invitational
Julian Smith, the Northern Ireland secretary, is another shock sacking after overseeing the restoration of the power-sharing government in Stormont last month - a notable achievement considering a resolution could not be found in the three years prior.
Ultra-loyal Alok Sharma, a former minister for global development, was appointed as the new minister for business and also the head of the COP26 climate change summit in Scotland in November, due to be attended by world leaders. The summit, known as the 26th Conference of the Parties, or COP26, is scheduled to be held in Glasgow in November.
Planning for that has got off to a rocky start, with Johnson last week firing Claire O'Neill, a former British government minister appointed previous year to head up the event.
The government said Thursday that Alok Sharma, previously in charge of global development, would become business secretary and also take charge of COP26.More news: Bouwmeester 'doing very well' day after collapsing in Blues game