According to the prosecutor, they have enough evidence to hold the man in custody.
"It's customary pre-trial measures: interrogations, searches and seizures. I mean that I have probable cause, but to be on the safe side, I have also gone in with the option of reasonable suspicion," Ewamari Häggkvist tells Swedish Radio's local P4 channel in Uppsala.
The alleged crime is said to have taken place at an "unknown location in Stockholm County and / or Uppsala County, reports news agency TT.
The man's lawyer was surprised by the court's decision.
"I'm very surprised based on the information I have received, but it is possible that the police and prosecutors have information that I do not have access. It will become clear eventually when I get access to the detention memorandum," the man's defence lawyer, Leif Silbersky, tells TT.
The suspect, who denies any wrongdoing, is said to be a resident of Bålsta. He was seized by police on Sunday evening and was kept for questioning until Wednesday morning's custody hearing in court.