The introduction of Arabic words into Spanish began in earnest in the eighth century, although even before then some words of Latin and Greek origin had roots in Arabic so people living in what is now Spain spoke Latin at one time.
Barrio is a noun pronounced 'bär-E-"O. It appeared in the early 1900s, stemming from the Arabic word barriya. It means "open country" as well as the feminine form barr meaning "outside" (of the city). In Hispanic countries it describes a district or suburb of a city.
Perhaps related to the English word borough, a barrio is also the actual name of a governmental unit in Spanish speaking countries including Puerto Rico. By 1841 barrio designated a 'ward of the Spanish or Spanish speaking city.' The noun is sometimes also used to describe rural settlements, from Spain.
By 1930 it was used in the modern sense of the word to indicate a Spanish speaking district in a U.S. city. This original American reference is to Spanish Harlem located in New York City.
Today the word has evolved in the United States, particularly the southwest, to depict a Spanish-speaking neighborhood. Slang terminology has taken it even further to mean in some highly urbanized cities to describe a red light district. The term has even been applied to on line communities with "cyber-barrios" where Hispanics can meet and help each other through the Internet.
Spanish's Arab Connection - Spanish Language:
Tango Terms and Etymology:
Many thanks to Gorgonzola for his insights about borough and barrio as a name for a governmental unit.