The prime minister made the promise as leaders of some of the richest countries on the planet gathered in Cornwall.
The Group of Seven - countries that have the largest IMF-described advanced economies in the world - are expected to collectively agree to provide a billion doses of Covid-19 vaccines in an effort to end the pandemic in 2022.
The leaders – including US President Joe Biden – will spend the day discussing issues including the pandemic before a lavish reception at the Eden Project attended by the Queen.
The Duke and Duchess of Cambridge will also take part in their first G7 events, another milestone in their progression as senior royals.
William and Kate will join the Queen, the Prince of Wales and the Duchess of Cornwall at the G7 leaders reception on Friday evening.
The summit, being held in Carbis Bay, begins with leaders of wealthy nations under pressure to do more to share the burden of protecting the world from the virus.
Mr Biden has already promised to donate half a billion Pfizer vaccines for 92 low and lower-middle income countries and the African Union.
Under the prime minister’s plan, the UK will provide five million doses by the end of September, with 25 million more by the end of 2021.
Listen to the ITV News coronavirus podcast
But he resisted calls from campaigners to take further action, including waiving patents on vaccines, insisting that the deal to supply Oxford/AstraZeneca jabs at cost price and the UK’s funding for the Covax initiative to provide doses around the world showed Britain was doing its share.
The prime minister told the BBC: “I think that the people of this country should be very proud that of the 1.5 billion doses that are being distributed around the world to the poorest and neediest in the world under the Covax programme, one in three come from the Oxford/AstraZeneca deal that the UK did, allowing those vaccines to be distributed at cost.
“And that’s before we’ve talked about the £548 million that we’ve contributed to Covax, £1.6 billion to Gavi (the vaccine alliance).
“And, yes, we’re putting in five million doses by September, but we’ll do … 100 million before 12 months is out. That’s a huge number of extra doses”
The G7 as a whole was offering a “colossal sum of vaccines”, he said.
Around one-fifth of the doses promised by Mr Johnson will be delivered through bilateral arrangements with countries in need while the rest will go through the Covax initiative which is distributing vaccines to poorer nations.
Downing Street said that by sharing five million doses in the coming weeks the UK will meet an immediate demand for vaccines for the countries worst affected by the pandemic without delaying completion of the domestic vaccination programme.
Vaccine minister Nadhim Zahawi told ITV News that the pledge would not "impact our domestic deployment of the vaccination programme.
He added: "Our first duty remains to the safety of the British people" and said that the "booster campaign" would also not be affected.
All adults in the UK will have been offered a first vaccine dose by the end of July under government plans.
Officials hope vaccinating people around the world will save lives, reduce the spread of the virus and restrict the emergence of new variants which could potentially be more dangerous than existing coronavirus strains.
At the summit, which runs until Sunday, the leaders of the UK, US, Canada, Japan, France, Germany and Italy will pledge at least one billion coronavirus vaccine doses to the world through dose sharing and financing.
They will also set out a plan to expand vaccine manufacturing in order to achieve that goal.
The prime minister will ask the group to encourage pharmaceutical companies to adopt the Oxford-AstraZeneca model of providing vaccines at cost price for the duration of the pandemic.
Pfizer, Moderna and Johnson & Johnson have already pledged to share 1.3 billion doses on a non-profit basis with developing countries.
Zoe Abrams, executive director at the British Red Cross, said the promise on vaccines was “heartening” but added: “While every commitment must be welcomed, more needs to be done, and fast.”
The days leading up to the summit have seen Mr Johnson engaged in rows with the European Union and US over Brexit and with his own backbenchers, including predecessor Theresa May, over the cut in the UK’s aid spending.
The UK has gone back on a commitment to spend 0.7% of national income on overseas aid, cutting the amount to 0.5% due to the economic carnage caused by the pandemic.
But the donation of vaccines will count as extra aid spending on top of the £10 billion already promised under the reduced target.
Mr Johnson said “people will understand that there is a pandemic which could not have been foreseen at the time we made that commitment to 0.7% throughout this parliament” and they are “incredibly proud of what we’re doing in spite of the difficulties that we’re facing”.
The response to the pandemic is one of the main themes of the summit, which is taking place amid tight security, both against criminal threats but also the risk posed by the virus.
Those attending, including the world leaders, will be tested regularly while the size of delegations and the number of press in attendance will be limited compared with previous summits.
There are no plans for the prime minister to shake hands with his counterparts and social distancing will be maintained during set piece events such as the traditional summit “family photograph”.
He will hold meetings with Japanese counterpart Yoshihide Suga, Canada’s Justin Trudeau and Italy’s Mario Draghi in the margins of the summit on Friday.