That's a huge and thorny issue. I had an experience eight years ago that was pretty interesting in hindsight. A contract worker our team worked in was brought onto our team full time. After I worked with them in a full time capacity for some months, we were at happy hour one day and drank a few when they asked the question of what do I make. I decided to be honest and tell them, and they said, "So I -AM- getting screwed!!" It turned out their salary was a lot lower than mine.
Fast forward a few years when I found out about https://levels.fyi and I found out that, in reality, we were BOTH "getting screwed" and quite a bit too! :D