What you think about salary based on the location of where the employee lives?

I see that some companies do this, they pay the remote worker based on where he lives, I would like to know what do you think about this?

Ultimately I think it’s up to you what you negotiate and value yourself at, and if the company isn’t willing to pay that - that’s a different issue. Personally, I charge everything outside of my own home currency in USD.

This is dependent on where this question is coming from. In the freelancing world or where you own your own business, I would agree with @da5ha … If this is coming from a world where you are paying employees or are an employee in a specific location (not location independent) then there is a case in paying based on location. If you are trying to find employees in the large cities of California or New York, for example, you are going to have to receive/pay higher wage (competitively) based on these locations. You won’t be able to receive/pay small town or rural wages in most large cities when the cost of living is so much higher in those locations by comparison.