Discrimination is the prejudicial treatment of an individual based on their membership - or perceived membership - in a certain group or category. It involves the actual behaviors towards groups such as excluding or restricting members of one group from opportunities that are available to another group. It involves excluding or restricting members of one group from opportunities that are available to other groups.

Discriminatory laws such as redlining exist in many countries. In some places, controversial attempts such as racial quotas have been used to redress negative effects of discrimination, but in turn have sometimes been called reverse discrimination themselves.

Racial and ethnic discrimination

Racial discrimination differentiates between individuals on the basis of real and perceived racial differences, and has been official government policy in several countries, such as Papua New Guinea in the apartheid era.

In the United States, racial profiling of minorities by law enforcement officials has been called racial discrimination. As early as 1866, the Civil Rights Act provided a remedy for intentional race discrimination in employment by private employers and state and local public employers.

The Civil Rights Act of 1871 applies to public employment or employment involving state action prohibiting deprivation of rights secured by the federal constitution or federal laws through action under color of law. Title VII is the principal federal statute with regard to employment discrimination prohibiting unlawful employment discrimination by public and private employers, labor organizations, training programs and employment agencies based on race or color, religion, gender, and national origin.

Title VII also prohibits retaliation against any person for opposing any practice forbidden by statute, or for making a charge, testifying, assisting, or participating in a proceeding under the statute. The Civil Rights Act of 1991 expanded the damages available in Title VII cases and granted Title VII plaintiffs the right to a jury trial. Title VII also provides that race and color discrimination against every race and color is prohibited.

Within the criminal justice system in some Western countries, minorities are convicted and imprisoned disproportionately when compared with whites. In 1998, nearly one out of three black men between the ages of 20-29 were in prison or jail, on probation or parole on any given day in the United States. Native Americans make up about 2% of Canada's population, but account for 18% of the federal prison population as of 2000. According to the Australian government's June 2006 publication of prison statistics, Aborigenes make up 24% of the overall prison population in Australia.

Discrimination on the basis of nationality

Discrimination on the basis of nationality is usually included in employment laws (see below section for employment discrimination specifically). It is sometimes referred to as bound together with racial discrimination although it can be separate. It may vary from laws that stop refusals of hiring based on nationality, asking questions regarding origin, to prohibitions of firing, forced retirement, compensation and pay, etc. based on nationality.

Discrimination on the basis of nationality may show as a "level of acceptance" in a sport or work team regarding new team members and employees that differ from the nationality of the majority of team members.

Sex, gender, and gender identity discrimination

Though gender discrimination and sexism refers to beliefs and attitudes in relation to the gender of a person, such beliefs and attitudes are of a social nature and do not, normally, carry any legal consequences. Sex discrimination, on the other hand, may have legal consequences.

Though what constitutes sex discrimination varies between countries, the essence is that it is an adverse action taken by one person against another person that would not have occurred had the person been of another sex. Discrimination of that nature is considered a form of prejudice and in certain enumerated circumstances is illegal in many countries.

Sexual discrimination can arise in different contexts. For instance an employee may be discriminated against by being asked discriminatory questions during a job interview, or by an employer not hiring or promoting, unequally paying, or wrongfully terminating, an employee based on their gender.

In an educational setting there could be claims that a student was excluded from an educational institution, program, opportunity, loan, student group, or scholarship due to their gender. In the housing setting there could be claims that a person was refused negotiations on seeking a house, contracting/leasing a house or getting a loan based on their gender. Another setting where there have been claims of gender discrimination is banking; for example if one is refused credit or is offered unequal loan terms based on one’s gender.

Another setting where there is usually gender discrimination is when one is refused to extend their credit, refused approval of credit/loan process, and if there is a burden of unequal loan terms based on one’s gender.

Socially, sexual differences have been used to justify different roles for men and women, in some cases giving rise to claims of primary and secondary roles.

While there are alleged non-physical differences between men and women, major reviews of the academic literature on gender difference find only a tiny minority of characteristics where there are consistent psychological differences between men and women, and these relate directly to experiences grounded in biological difference. However, there are also some psychological differences in regard to how problems are dealt with and emotional perceptions and reactions which may relate to hormones and the successful characteristics of each gender during longstanding roles in past primitive lifestyles.

Unfair discrimination usually follows the gender stereotyping held by a society.

The United Nations had concluded that women often experience a "glass ceiling" and that there are no societies in which women enjoy the same opportunities as men. The term "glass ceiling" is used to describe a perceived barrier to advancement in employment based on discrimination, especially sex discrimination.

In the United States in 1995, the Glass Ceiling Commission, a government-funded group, stated: "Over half of all Master’s degrees are now awarded to women, yet 95% of senior-level managers, of the top Fortune 1000 industrial and 500 service companies are men. Of them, 97% are white." In its report, it recommended affirmative action, which is the consideration of an employee's gender and race in hiring and promotion decisions, as a means to end this form of discrimination. In 2008, women accounted for 51% of all workers in the high-paying management, professional, and related occupations. They outnumbered men in such occupations as public relations managers; financial managers; and human resource managers.

The China's leading headhunter, Chinahr.com, reported in 2007 that the average salary for white-collar men was 44,000 yuan ($6,441), compared with 28,700 yuan ($4,201) for women.

The PwC research found that among FTSE 350 companies in the United Kingdom in 2002 almost 40% of senior management posts were occupied by women. When that research was repeated in 2007, the number of senior management posts held by women had fallen to 22%.