The Croatian seized up as he got close to the finishing line, after he himself had come from a set down to take the initiative in Montreal.
Del Potro took the first set, but he never truly looked at ease on Central Court. The pair had exchanged breaks of serve, but it was the 2010 US Open champion who broke decisively at 5-4.
Dodig fought back in the second, breaking twice on his way to taking it 6-4 and levelling the match. Some questions over Del Potro's fitness were answered when he called for the trainer during the changeover to work on his lower back.
It was sloppy play that cost Dodig a memorable victory, although Del Potro used all his experience to hit solidly rather than going for the spectacular, and letting his opponent make all the mistakes.
In the end, it was a double fault that gifted the 6-4 4-6 7-5 victory to Del Potro, and he now goes on to face Milos Raonic in the third round.