The deal, which will earn the government a royalty payment of 24% of sales revenue, is non-exclusive and will enable companies other than Microsoft to market the system.
The Office of the E-envoy worked closely with Microsoft to develop the Gateway project, which allows legacy systems in different departments to communicate with each other and offers information on public services. Dell and Sema were also involved in the development.
Key clauses in the licensing arrangements ensure that the UK will benefit technically as well as financially from any future sales of the technology.
The government will receive complimentary upgrades of software developed by countries which buy the technology in order to ensure that the UK benefits from future deployments.
A spokesman for the Cabinet Office said: "This is an unprecedented deal which will ensure a huge recoup on the government's investment in the Gateway, as well as seeing British expertise exported abroad."
Jenny Duff, Microsoft's public sector industry manager, said: "We believe the deal is good for us and good for the UK government. It's a very practical decision because there has been so much overseas interest in the Gateway solution."
Danny Jones, the programme director at the consultancy Morgan Chambers, agreed that the royalty rate was impressive and predicted the deal would prove to be very profitable for the UK government.
Gateway has delivered solid performance since its launch in January 2001 and has attracted attention from overseas governments looking to deliver online public services.
Jones added: "This system has a demonstrated capability that should be easy to sell abroad and with Microsoft doing the marketing this should mean big business for all."