A substitute teacher from California has been fired and arrested after a student found her in a video on Pornhub having sex with a female relative.

A student of St Elizabeth Seton Catholic School in Palo Alto spotted fourth grade teacher Dawn Giannini, 49, in an explicit video with an underage teenager, The Daily Mail reports.

The student sent the video to the school's principal, who alerted police. Prosecutors say the female relative featured in the video was the one that posted it to Pornhub.

The Daily Mail didn't report how she was related to Giannini, but did say she 14 at the time of the crimes, which took place from November 2014 to November 2015.

"We know that this occurred in at least two counties," San Mateo County District Attorney Steve Wagstaffe told The Daily Mail.

"It occurred here in our county, in Redwood City and there was a trip down to Santa Cruz that she took with the victim and there was sexual activity there."

Giannini is married with two teenage children. Her husband, Thomas Giannini, is a decorated member of the military who had served overseas in Iraq and Afghanistan.

Neither the school, nor prosecutors, believe Giannini assaulted any of her students, but the DA is looking into all areas of the case.

She remains jail in lieu of a US$1.75 million (NZ$ 2.6 million) bail.

Newshub.