The Red Devils welcomed the Championship side to Old Trafford in the cup clash as Jose Mourinho came up against his former Chelsea FC vice captain Lampard.
The retired England midfielder took over the reins of Derby in the summer as Lampard got his managerial career under way.
Juan Mata scored in the third minute to ease Manchester United into an early lead before Harry Wilson and Tom Marriott turned the third-round tie on its head.
Belgian midfielder Marouane Fellaini levelled the cup clash in the fifth minute of added time to force extra time and penalties.
However, Lampard’s side emerged 8-7 winners on penalties to secure their place in the fourth round and earn the Chelsea FC legend his biggest scalp in his fledgling managerial career so far.
Former Manchester United defender Ferdinand was quick to heap praise on Lampard and his Derby team for a deserved win.
Ferdinand wrote on Twitter: “Congrats to Lamps.. @morriskid & his @dcfcofficial team tonight… Deserved Win! #MUFC #DCFC”
Manchester United will make the daunting trip to West Ham United at the London Stadium in the Premier League at the weekend.
MORE: Man United latest news
MORE: Arsenal latest news
MORE: Chelsea latest news
MORE: Liverpool latest news