10 Job Interview Questions That Aren't Legal Credit: Peshkova/Shutterstock

While you want to learn as much as you can about job candidates during an interview, asking certain questions can get you in serious hot water.

When it comes to determining the questions that are and aren't appropriate to ask, the limitations aren't always clear. Twenty percent of hiring managers have asked a question in a job interview only to find out later it was illegal to ask, according to a new study from CareerBuilder.

For the protection of both the interviewer and interviewee, it's important to understand what employers do and don't have a legal right to question job candidates about, said Rosemary Haefner, the chief human resources officer at CareerBuilder.

"Though their intentions may be harmless, hiring managers could unknowingly be putting themselves at risk for legal action, as a job candidate could argue that certain questions were used to discriminate against him or her," Haefner said in a statement.

To help hiring managers, CareerBuilder has identified some of the most common questions that employers didn't know were illegal:

  • What is your religious affiliation?
  • Are you pregnant?
  • What is your political affiliation?
  • What is your race, color or ethnicity?
  • How old are you?
  • Are you disabled?
  • Are you married?
  • Do you have children or plan to?
  • Are you in debt?
  • Do you socially drink or smoke?

Sometimes the legality of the question is in how the interviewer asks it, according to CareerBuilder. For example, when discussing a candidate's retirement plans, asking what his or her long-term goals are is OK, but asking when they plan to retire is not acceptable. [5 Sticky Job Interview Situations (And How to Handle Them Like a Pro )]

Other examples of questions hiring managers need to be careful how they ask include:

  • Where do you live? CareerBuilder saysasking candidates where they live is illegal because it could be interpreted as a way to discriminate based on their location. The better way to phrase the question is to ask them if they're willing to relocate.
  • What was the nature of your military discharge? Asking why a military veteran was discharged is illegal, according to CareerBuilder. However, employers can ask what type of education, training or work experience a candidate received while in the military.
  • Are you a U.S. citizen? While you can ask if a candidate is legally eligible for employment in the U.S., it's illegal to ask about citizenship or national origin, according to CareerBuilder.

The study was based on surveys of 2,100  hiring and human resource managers across a variety of industries.

Dave Mielach also contributed to this story.