WASHINGTON (AP) _ District of Columbia officials say outsiders are to blame for much of the city's homeless problem, but homeless rights advocates reject the notion that people move here from nearby suburbs to receive free shelter.

The debate has been raging since before voters passed Initiative 17, the Right to Overnight Shelter Act, in November 1984, requiring the city to provide shelter to ''all persons in the District of Columbia.''

Mayor Marion S. Barry Jr. had lobbied against the referendum, saying it would attract outsiders to the District to take advantage of free services. More than four years later, he says that has happened.

''Washington is 22 percent of the region's population,'' Barry said during a news conference late last year. ''Yet we have 78 percent of the region's homeless. ... In every area of dependency, we have a disproportiona te share - not because people here are poor, but because Maryland and Virginia are not carrying their fair share.''

Barry spokesman John White said there were ''no hard stats'' to back up the mayor's assertion, but that when the mayor toured a newly opened shelter in January, half the people to whom he spoke said they were from out of town.

''It's a myth to think that homeless people are mobile and have the means to travel from around the country in order to get services,'' said Maria Foscarinis, an attorney with the National Coalition for the Homeless.

''Homeless people are generally destitute. They lack transportation money. It's hard enough to get from one side of the town to another, let alone from one part of the country to another.''

D.C. officials estimate there are less than 10,000 homeless in the nation's capital, but homeless advocates say the number is closer to 15,000.

Ray Spicer, homeless coordinator for neighboring Arlington County, Va., acknowledged that his county is short on shelter space. Arlington provided shelter for more than 1,200 people during all of 1988, turning away 2,100, he said. But those who couldn't find a place went elsewhere in northern Virginia, not into Washington, said Spicer.

Christine Felker, assistant director of the Prince George's County, Md., Department of Social Services, said, ''I believe that people are crossing the lines both ways.''

Ms. Felker said the county, which focuses on helping homeless people and families ''get back on their feet,'' sheltered more than 4,500 people last year, but turned away 5,100.

Homeless rights advocates said Barry's assertion reflects the common practice of political leaders to blame the problem on outsiders.

''Every single mayor in the country is saying exactly the same thing,'' said Ms. Foscarinis. ''It's a typical response, no longer novel, by mayors who want to avoid their responsibility to aid the homeless.''

Initiative 17 isn't drawing homeless persons here, homeless advocates insist.

''People don't bounce around for a bed and shelter,'' said Mitch Snyder, whose Community for Creative Non-Violence runs a 1,400-bed shelter near the U.S. Capitol. ''People have as much a sense of place, whether they have a roof over their head or not, as people who live indoors. People only move for jobs.''

Other shelter operators reported similar experiences.

''The vast majority of our women are D.C. residents,'' said Ellen Rocks, director of the House of Ruth, which shelters homeless and battered women and children. ''The sense of people transitioning into D.C. because the services are so good strikes me as absurd.''

Pam Hollar, who directs the Luther Place Emergency Shelter for Women, said, ''From being on the inside, I'm not sure that D.C.'s such an attractive place.''

Information about those who stay in city-run shelters is not available, although a computer system is being implemented to better track shelter residents, said D.C. homeless coordinator Sue Marshall.

Council member Nadine Winter proposed a bill in February designed to ensure that residents get priority for long-term homeless services such as job training and drug counseling. She did not specify how homeless people could prove residency.