Lima, Peru— When someone mentions Peru to you, what is the first visual image that pops into your head? Inca Indians with their llamas in the Andes Mountains, looking at the some of the stone ruins of their ancient civilization? Yes, Peru still does have some of that, but most Peruvians are now employed in an increasingly rapid-growing and diverse economy.

In 1985, Peru was very poor with almost the lowest level of economic freedom in the world. In the early 1990s, former President Alberto Fujimori began major economic reforms. These reforms have continued through a series of administrations, including that of the current president, Ollanta Humala. Peru is now listed as the 20th most-free economy in the world, according to the Economic Freedom of the World 2014 Annual Report. As a result of the economic liberalization and increase in economic freedom, Peru enjoyed an average rate of real economic growth of about 5.5 percent from 1994 to 2013. At that rate of growth, per capita income doubles about every 14 years (please see accompanying chart.) Peru did not begin its economic reforms until almost a decade after its neighbor to the south, Chile, began its reforms and resulting economic takeoff. Starting late and from a lower base, Peruvians only enjoy about half the real income per person of Chileans.

Economic growth slowed a bit last year and will slow further this year owing to the decline in the price of copper, gold, silver and other commodities that are its major export industries. However, if Peru can revive the growth rate of its economy back to 5 percent or more by further economic diversification and increasing economic freedom, in a decade and a half it could enjoy the per capita incomes that Chileans experience today, and it would be essentially a “developed economy.” Peru is still plagued by too much corruption, a semi-dysfunctional legal system and many regulatory inefficiencies. On the positive side, Peru has opened up its markets and concluded many free-trade agreements, including one with the United States, which has given its businesses access to much of the global market. In Peru, government spending and debt are less than 20 percent of gross domestic product, which is a definite plus.

Almost one-third of the 30 million Peruvians live in Lima, a sprawling city between the Pacific Ocean and the Andes mountains. It has a surprisingly mild and pleasant climate even though it is only about 10 degrees south latitude from the equator. It also has many historical sites and world-class museums. In addition to GDP per capita, there are other measures of success, such as the level of adult literacy, which has risen rapidly.

Many poor countries pay little attention to their historical culture. As countries increase their real per-capital incomes, they usually stop destroying significant historical ruins (even though they are in the way of population growth and development) and start preserving them — if for no other reason than they can be money-making tourist attractions. For example, here in Lima, a new highway project was slated to split in two a large ancient Incan palace and burial complex with many artifacts that had been only partially explored. But after protests, it was decided to build a series of automobile tunnels under the complex, which is due to be completed in June. Now Lima will have both improved transportation and a more accessible and preserved historical site.

Another example of increasing political accountability and maturity is the reaction to government wrongdoing. Peru’s prime minister, Ana Jara, took swift action last week after the local press uncovered alleged extensive spying on well-known Peruvians. She fired the head of the National Intelligence Service and a number of other officials, even though she is an ally of President Humala. Many countries, including the United States, have suffered repeated scandals in which intelligence, law enforcement and tax officials misuse their power. The fact that government officials almost everywhere abuse power is not surprising (which is one of the many reasons to limit the size and authority of government). The reaction to such discoveries by government officials differentiates responsible from irresponsible governments. U.S. citizens are still waiting for the housecleaning that is obviously needed at the Internal Revenue Service and some other agencies. It would be ironic if Ms. Jara, as the Peruvian prime minister, proves to be more decisive and responsible in dealing with corruption in her government than President Obama is in dealing with corruption and irresponsibility in his.

Given the progress that Peru has made in recent decades on many fronts, there is good reason to be optimistic about its future.