A man who tricked a Victorian woman into having sex with him by pretending to be a blond man called Jamie has escaped a jail sentence.

In 2012, Deepak Dhankar, posing as Jamie, met the woman through an online dating site and agreed to meet at her house.

They agreed he would let himself into the house and into her bedroom, where she was in bed pretending to sleep.

The woman kept her eyes closed throughout the sexual encounter, but when she opened her eyes she realised Dhankar was not Jamie.

Her children were in the house at the time.

Dhankar, who is now 29, pleaded guilty in the County Court to procuring sex by fraud, and was sentenced to 200 hours of community service.

In sentencing, Judge Jane Patrick said Dhankar was a low risk of reoffending and showed genuine remorse.

"It is a serious matter to obtain access to another person's body by deception," she said.

"It appears that you chose this extremely selfish, immature and inappropriate way to deal with your frustrations arising from the problems you and your wife were having.

"You were clearly aware of the importance of physical appearance in connection with internet dating and in the arrangements that you were making with the complainant."

Judge Patrick noted Dhankar and his wife were "working to maintain a positive relationship" and to support their three children.

She also issued a warning to anyone engaged in internet dating.

"I would urge all people of whatever gender or age to be very careful about accepting the truth of online descriptions and to be extremely cautious about allowing a virtual stranger to enter their home," she said.

She added that there was no suggestion Dhankar intended to harm the complainant.

Dhankar was born in India and moved to Australia to study in 2003.

He is now an Australian citizen.

Dhankar did not speak outside court.