The 27-year-old, who joined the Shrimps from Hereford in 2006, initially joined the Gulls for a month in January and has so far made 10 appearances for the club.
Stanley told Torquay's official website: "I've enjoyed my first month and I'm happy to extend the loan until the rest of the season.
"The lads have helped me settle and you never know what it's going to be like at a new team.
"The way the team plays and the way the manager wants to play suits my game. I'm grateful for the way everyone has been with me in the first month and I'm looking forward to the rest of the season."
The paperwork has been completed in time for Stanley to be included in Torquay's squad for the midweek home match with Rotherham.
Source: PA
Source: PA