CHICAGO, Illinois (CNN) -- A magistrate judge on Monday granted bail for an Illinois man accused of surreptitiously taping sports reporter Erin Andrews in the nude and posting the videos on the Internet.

ESPN reporter Erin Andrews was allegedly stalked by a man who posted nude videos of her on the Internet.

Michael David Barrett, 48, will return to California to face a federal charge of interstate stalking.

U.S. Magistrate Judge Arlander Keys agreed Barrett would be released on bail. However, Keys ordered that Barrett be confined to his home and subject to electronic monitoring, the Chicago Sun-Times reported.

Barrett, an insurance company employee from Westmont, Illinois, is accused of taping Andrews, an ESPN reporter, while she was nude in two hotel rooms. He then made seven videos that he posted on the Internet, according to a criminal complaint filed in the case.

Barrett was arrested Friday at Chicago O'Hare International Airport. He will appear in court in Los Angeles, California, on October 23, according to a statement from prosecutors in Los Angeles.

Authorities believe most of the videos were made at a Nashville, Tennessee, hotel in September 2008. The peephole into Andrews' room was altered with a hacksaw, and the images appeared to have been taken with a cell phone camera, the complaint said.

Investigators found in hotel records that Barrett had requested and received a room adjacent to Andrews' and used his home address to register for it.

Don't Miss

Barrett allegedly attempted to sell the videos to celebrity gossip site TMZ in January 2009. TMZ did not purchase the photos, but employees of the Web site assisted in the investigation, providing information to Andrews' attorneys, authorities said. However, Barrett posted the videos to other Web sites, the criminal complaint said, with labels like "Sexy and hot blonde sports celebrity shows us her all."

"The e-mail (sent to TMZ) was linked to Barrett through a number of methods," the statement from Los Angeles prosecutors said.

Investigators found that Barrett reserved a room at a Milwaukee, Wisconsin, hotel where Andrews was staying in July 2008 but never checked in, according to the complaint and prosecutors' statement. "However, the peephole on the door where the victim stayed during that trip was altered in a similar way to the peephole found in the Nashville hotel," the statement said.

Andrews, 31, is a sideline reporter for ESPN, traveling around the country covering college football games. The criminal complaint against Barrett, which identifies Andrews only as "Individual A," says she became aware of the videos in July, and that their posting has caused her distress, anxiety and trouble sleeping.

Authorities believe Barrett could have recorded similar videos of other women in the same manner, the criminal complaint says. Investigators found other videos on a Web site, apparently posted by a person using the same username as the person who posted the Andrews videos. "From the screenshots of these videos, it appears that these videos have also been taken of naked women through the peephole of a door," the complaint said.

In Monday's hearing, prosecutor Steve Grimes called Barrett's interest in Andrews an "obsession," the Sun-Times reported.

"This was not just a whimsical act," Grimes said. "This was an obsession, one that was acted out ... one he carried out through various states."

Grimes described Barrett as a danger to women.

A call to Andrews' attorney, Marshall Grossman, was not immediately returned.

In an interview Monday with Chicago's WGN-AM, Grossman said Andrews was initially "quite relieved" after a suspect was identified and arrested. However, he said, in reviewing the affidavit, Andrews' "concern returned, unfortunately, in spades, so to speak, because of the extent of the charges as outlined by the FBI (and) the fact that this has been going on for several months in numerous locations. ... Her distress level is naturally quite high, and she hopes that this matter is brought to resolution as soon as possible so she can return to some sense of normalcy in her professional job and responsibilities."

Barrett's father, Frank Barrett, told the Sun-Times on Sunday that the allegations do "not match the Mike I know," describing his son as "an extrovert and very outgoing." He told the newspaper his son is divorced but has a college-age daughter.

The magistrate placed Barrett on a 9 p.m.-to-6 a.m. curfew and ordered him not to use the Internet at home or at work. He will be allowed to go to work but must be at home the rest of the time, the Sun-Times said.

A search warrant in the case directed authorities to search Barrett's computer for information in the case, including anything "relating to Individual A, a female reporter for ESPN, including but not limited to her travel schedule," as well as information relating to hotels where Barrett has stayed, among other items.

Grimes said in court that the warrant was executed Saturday, according to the Sun-Times.

The maximum penalty for the charge of interstate stalking is five years in federal prison, the FBI said.