In California, employees doing similar work for the same company should be paid similar amounts. This is true in many cases even if, say, Employee A has a master's degree while Employee B has a bachelor's. The same idea applies to something such as one year of experience versus five years of experience upon hire.
Employers used to deploy such measures as a way to pay some employees more. Often, these employees would be white and male. Now California has also banned salary history inquiries, meaning that employers cannot ask you about your salary history. If you volunteer the history, the employer can use that as one factor in deciding what to pay you. Employers must also offer pay scales to job candidates upon reasonable request. This helps you self-select for jobs and should cut down on pay discrepancies for employees doing similar work. All that said, what if you find out that you make less money than one of your co-workers performing similar work? What should you do?
Discrimination could be at play but maybe not
In the absence of any evidence of conscious discrimination, it could be factors such as ignorance, a different jobs-in-demand environment or different hiring managers that led to the variable pay levels. Of course, that does not mean it is fair for you to receive lower pay. Document what is happening and go to your manager or HR rep with the information you have. Ask why you are not being paid more similarly to your co-worker. It could be that your co-worker does extra work you are unaware of or has a relatively rare credential that he or she uses in work.
Consult an attorney
However, if such a meeting yields unsatisfactory results and there are no apparent valid reasons for you to be paid less, your employer could be discriminating against you due to your gender, race, sexual orientation or other protected reason. You may have legal options that allow you to pursue a fair wage.