Amazon’s recent decision to increase the hourly minimum wage for its workers to $15 was made for the right reasons.

The choice to pay workers more was largely market-driven. Faced with stiff competition for workers in the strong U.S. economy, Amazon owner Jeff Bezos rightly raised the minimum for the company’s more than 575,000 employees worldwide. The increase puts more money in workers’ pockets and gives them more purchasing power — an important economic measure for retailers such as Amazon.

As many economists note, corporate profits in the U.S. are booming, and the healthy economy gives workers more job options. That means firms like Amazon have to find ways to recruit more employees. Raising the minimum hourly wage not only wins the company public relations points, but it’s also a change born of economic necessity.

The huge online retailer is a fast-growing, $900 billion company that has made Bezos the richest man in the world. As it has expanded from selling books to offering nearly everything else, it has become the second-largest employer in the country. It can afford to share more of that success with the employees that make it happen.

But that’s not the financial story for many American businesses, especially many smaller companies that represent the majority of U.S. employers. That’s why prematurely imposing higher-than-market minimum wages — as Minneapolis and some other cities have done — can have unintended negative consequences.

In regions and towns with lower costs of living, a lower wage can still provide workers with a good standard of living. And some employers with low profit margins facing mandated wage increases offer fewer jobs or hours.

For Amazon, paying a higher wage will help the company find and retain employees while also blunting some of the criticism it has faced for treating employees poorly. And the $15 minimum should help lower-skilled employees, reduce turnover, minimize retraining costs and attract better job applicants.

In Minnesota, Amazon employs more than 2,000 full-time workers, most of them at a large fulfillment center in Shakopee. The company has a smaller sorting center in Shakopee, a transportation delivery station in Eagan and a Prime Now hub in southeast Minneapolis. And earlier this year, the company announced plans to hire an additional 200 engineers and other IT workers for its tech hub in the North Loop in Minneapolis, where it already has about 150 employees.

Before the move to the $15 minimum, Amazon had been criticized by Sen. Bernie Sanders of Vermont and President Donald Trump for its treatment of lower-paid employees. And there’s been skepticism from some quarters about the wage hike because the company will cut the opportunity for bonus pay for some employees. But on balance, the positive impact of the increase will outweigh any negatives.

“We listened to our critics, thought hard about what we wanted to do, and decided we want to lead,” Bezos said in a statement. “We’re excited about this change and encourage our competitors and other large employers to join us.”

Some of that is already happening. Last year, Minneapolis-based Target announced that it would raise its minimum pay to $15 an hour by 2020.

Amazon’s decision is welcome. It not only helps thousands of the company’s employees, but it sends a signal to other large, growing and profitable U.S. companies.