"Foreigners can become freehold property owners in areas designated by the ruler," said the text of the law, reprinted in several newspapers.
"They can also derive benefit from their property or rent it out for a period not exceeding 99 years."
Foreigners make up more than 80% of Dubai's estimated 1.2 million population.
Until now, property ownership was limited to residents of the United Arab Emirates (UAE) and other nationals of the Gulf Cooperation Council, which also includes Bahrain, Kuwait, Oman, Qatar and Saudi Arabia.
Previously foreigners who bought property in Dubai's bustling real estate market, such as British football star David Beckham, received a deed from the major developing companies. These companies are effectively owned and controlled by Dubai's government and its ruler, Sheikh Mohammed bin Rashid al-Maktoum, and his family.
"Passing a law that authorises foreigners to buy property is a real gain for the market and investors," said Mohammed Ali al-Abbar, chairman of Dubai-based EMAAR Properties, the world's largest real estate firm in terms of market capitalisation.
EMAAR is involved in several
"The massive projects that are being built now would have hit serious problems if the issue of freehold ownership had not been resolved."
EMAAR, which lists the Dubai government as its largest shareholder, has built 12,800 homes in the city.
It is involved in several mega projects including the Burj al-Arab Tower, which aims to be the world's tallest building at some 800 metres (2500 feet) high.