The duo, who took over at The SRD Stadium last summer from Steve Bateman after he left at the end of the 2015-16 campaign, stood down on Wednesday following the club's 3-2 defeat at home to Barton Rovers in the Southern League Cup on Tuesday night.
The Moles say the pair, pictured, resigned with just under half the season still to go to give their successor or successors at the third from bottom club the best possible chance of beating the drop and securing their EVO-STIK League Southern Division One Central status.
In a statement thanking them for their services and wishing them well, a spokesman said: "It's been a difficult time for the pair as the majority of last year's squad had left and they had the task of completely rebuilding the squad for this season.
"The results and performances have been inconsistent as the management team struggled to find the right formula and they have now decided that with a fair proportion of the season still to play, they want to give the club the best chance to try and allow a replacement to turn the team's fortunes around.
"Everyone at the club would like to thank Danny and Gareth for their hard work and commitment to the cause and wish them all the best in the future. Details of the new management team will follow shortly."
Follow the EVO-STIK League Southern on Twitter at @SouthernLeague1