Defender Shephard and forward Hedges arrived in the summer initially on loan deals until January.
Hedges has started every match for Town whilst Shephard featured in the opening two fixtures before injury ruled him out for two weeks.
Swans manager Francesco Guidolin has agreed to allow the Wales Under-21 internationals to continue their development in Somerset.
Manager Darren Way was delighted with the extension of their loan deals.
He said: “I think it’s a fantastic move for both parties - Swansea and Yeovil - that both players have decided to extend their loan deals until the end of the season. It shows what direction this Football Club is going in.
“Both players have been great additions to Yeovil Town and I’m sure that’s only going to get stronger as the team keeps growing.”
Both deals are subject to international clearance.