Gurjinder Ghorta, 23, is facing felony charges in two towns. Prosecutors said text messages he sent to the girl last week contain explicit comments that paint a picture of a dangerous man.

"He is accused, through the use of a cellphone social media app, of having contact with an underage female in Derry," prosecutor Jason Grosky said. "He is accused of arranging a meeting with her, encouraging her to sneak out of her house in the middle of the night."

According to court paperwork, the two met through the social media app Kik and later exchanged text messages.

Investigators said Ghorta picked the girl up near Windham Road in Derry and then took her to a Salem motel. Police said he sexually assaulted the girl there.

Ghorta's attorney said he has no criminal record and would return to his family in Brooklyn if he's released.

It's unclear why he was in New Hampshire, but prosecutors said he had recently visited the area of Worcester, Massachusetts. He is a native of India.

Ghorta waived his probable cause hearing in Derry and is being held on $250,000 cash-only bail.

Ghorta was ordered to stay away from the girl and told to not use a computer or online device, including social media apps on cellphones.