When a job interviewer asks you what your salary is, it can really put you on the spot – especially if you are a woman or an older worker. Women who admit to a low current salary may find it difficult to get the wages they deserve. And older workers may be considered “too expensive” for a position, based on past salaries, even when they are willing to earn less. (See also: 7 Tips for Getting the Salary You Deserve and Employment Negotiations: What to Ask for & How.)

For the reasons above, as well as others, you may wish you could duck that salary question. And soon that may become easy, as new city and state legislation banning that line of questioning becomes law.

Cities and States Taking the Lead

Philadelphia recently joined Massachusetts and New York City in passing legislation that bans employers from querying job interviewees regarding salary. Illinois, Maine, Maryland, New Jersey, New York, Pennsylvania, Rhode Island and Vermont are also considering similar bans aimed at closing the salary disparity between men and women. Currently, women make about 80 cents for every dollar earned by men, according to the U.S. Census Bureau.

In Philadelphia the new law is intended to become part of the Philadelphia Fair Practices Ordinance. It prevents private sector employers from asking job applicants about their salary history and retaliating against prospective hires if they don’t disclose the information. If an employer learns of a person’s salary history, the employer may not make hiring decisions based on the information.

Massachusetts Governor Charlie Baker signed a law in August 2016 that not only makes it illegal for employers to ask applicants about salary history, it also stops employers from banning employees from discussing their salaries with one another. Conversations about salary among workers are often needed for a female worker to file a discrimination challenge. The bill is slated to go into effect July 1, 2018.

Not Everyone Is on Board

Although it’s hard to argue with wage equality these days, opponents say that a law isn’t going to solve the problem. In the case of Philadelphia, the city voluntarily postponed implementation of the law until a lawsuit filed by The Chamber of Commerce for Greater Philadelphia has been resolved.

The Chamber argues that the new law violates free speech and other constitutional rights and that it isn’t written in a way that directly targets the issue of gender wage discrimination.

The State of Pennsylvania has legislation pending on the subject, but it, too, faces challenges alleging that the proposed law doesn’t directly address the problem.

Efforts in California and New Jersey were vetoed; in Virginia, a proposal was tabled indefinitely; and in Washington, D.C., a proposed ban died when the city council adjourned.

Public vs. Private Sector

The battle rages on for private sector employers, but such bans already exist in a number of public agencies. Those in New York state and New York City are no longer allowed to ask for salary history before making a salary offer. And New Orleans and Pittsburgh no longer allow wage questions to be asked.

Even Congress almost took on the issue. H.R. 6030, the Pay Equality For All Act of 2016, would have made it illegal to ask the salary question, but the bill ultimately died in committee.

The Bottom Line

It might be too soon to see major movement in the private sector, but some attorneys argue that if public agencies are embracing the ban, it’s only a matter of time until the private sector is mandated to do the same. Human resources departments are advising employers to start reviewing their hiring process before new laws force a change. For now, however, you may be forced to answer that difficult question or be put on the spot if you politely decline.

Want to learn how to invest?

Get a free 10 week email series that will teach you how to start investing.

Delivered twice a week, straight to your inbox.