Royal Museums Greenwich launched a £10m fundraising scheme in May before the painting came up for sale. The appeal ultimately raised £10.3m, including £7.5m from a Heritage Lottery Fund grant, a £1m grant from Art Fund and £400,000 from the Museum.
An additional £1.5m was raised from 8000 public donors.
Art Fund director Stephen Deuchar described the campaign as “a triumph of popular will.”
Deuchar added: “Record numbers of donors, large and small, stepped forward with determination and generosity creating an irresistible momentum that has brought this great work into public ownership at last.”
Other major contributions were also made by the Linbury Trust, the Garfield Weston Foundation and the Headley Trust.
The Armada Portrait of the Queen was once owned by Sir Francis Drake. It will hang in the Queen’s House which is built on the original sign of Greenwich Palace where Elizabeth was born.
It is set to go on view on October 11.