Are humans more attracted to people from their own ethnic groups? I ask this because most of the time people have relationships with people of their own ethnicity, and I wonder if it's purely social, or if there's more behind it.
The answer in extreme brief is yes. Only about 9% of whites and 16% of blacks engage in interracial marriage in the U.S.
But really this deserves a fuller discussion.
The predominant pattern of mate selection in human beings is to marry within their ethnic group. I say 'ethnic group' rather than 'race' because 'race' has no strong scientific definition. Racial groups as usually understood have about the same genetic variance as the overall species. I need to point out here that races can have a strong geographical point of origin and thus races can in some cases be genetically identified, but these correlate poorly often with, say health risks or other clinical data.
Because its clear that interracial marriages are on the rise in the US, mating choices are often argued to be socially defined preferences. Social attitudes affect men and women differently and different cultures too, as tracked by regional differences. Not the least is a limit of opportunities. Being comfortable with people from other cultures or who simply look different.
Interestingly, Women at least in American studies are much more likely to state a same-race preference (see p17), while men are likely to demur from stating a preference, but act out a bias unconsciously, making both genders equally biased.
As mentioned in the comments by @AliceD, Mating preferences as described in traditional population biology are adapted from availability. That's to say people don't meet because of ethnic boundaries such as geography, socioeconomic or social strata. Then there are socialized preferences. I.e. growing up we are imprinted by the sorts of people we see, which can create preferences later in life.
Lastly there may be genetically conveyed preferences. The human race has been spreading out over the past 200,000 years or so. That's a pretty small amount of time.
There are cases where such mating preferences have evolved. There are 17 species of arctic penguins, species caused by migration around the globe. Each species can actually mate with others nearby, but where the penguins met at the far end of the globe, the species do not mate because they have been separated for so long they have diverged.
But speciation events can take millions of years. Its clear that human beings from the far corners of the globe can produce offspring - we are one species. It seems as if we are only a fraction of the way towards two neighboring penguin species in the example above. There doesn't seem to be any evidence that we are genetically predisposed to ethinic self mating.
Only by way of example (not to offend anyone!) you can choose an ethnic group which has divergent behavior and try to get an estimate of how big a role the social context plays. Looking at the jewish community we see that 47% of jewish people have married out of group in recent statistics. They are thinly distributed over a wide geographical region and availability is high for out-group marriage. All this while orthodox jews have a practically non-existent out-group marriage rate. Not judging here, but only for illustrative purposes we can guess that social attitudes and behaviors are playing a large role here.
As and endnote, I'd also like to point out that since whites are about 50% of the US population and african americans are about 10%, the percentages not so disparate as they seem - all things being equal the average person one meets in the US is white. For caucasians, approximately 50% of the population the average interracial marriage rate with no racial biases is is 50%. For blacks its 90%. Again, just using random shuffling for statistical point of view.
To keep it simple: The term here is assortative mating which describes the tendency of individuals to select reproductive partners based on some arbitrary measure of "likeness" considering the available within-species variation. The "likeness" could be anything from a general evaluation to being based on one specific trait.
This is a evolutionary significant phenomenon, and when it comes to humans there are a lot of factors that seems to be related to human assortative mating, including both race (whatever the term's biological significance) and ethnicity, among other things like height, religion, politics and even altruism. See wiki for ref.
As seen in the article Shigeta liked to, racial belongingness is generally very significant in human assortative mating.
So the concept of choosing "similar" partners as we see in humans is a common biological phenomenon with evolutionary significance, although by what exact mechanisms this selection works in humans and how culturally dependent it is (maybe some assortative selection traits are more or less biologically/culturally founded than others) is probably in need of more research.