in the nick of time

US /ɪn ðə nɪk əv taɪm/
UK /ɪn ðə nɪk əv taɪm/
"in the nick of time" picture
1.

at the last possible moment; just in time

:
The rescue team arrived in the nick of time to save the stranded climbers.
I finished my presentation in the nick of time before the meeting started.