The word salary hides a mineral. It comes from the Latin salarium, derived from sal, salt.
In ancient Rome salt was not the cheap seasoning we take for granted today. It preserved meat and fish before refrigerators existed, which made it a strategic good, almost a currency. The salarium was an allowance connected to salt, paid to soldiers and officials; from there it came to mean, quite simply, the pay for a job.
From the same root come salad (salted greens), sauce and even the expression that someone is not worth their salt. Every time you get paid at the end of the month you are repeating, without knowing it, a word born in a Roman salt store.
Source: Real Academia Española, Diccionario