At the programming level, the Uno and Nano (Atmega328p) are nearly identical.
The 'standard' Nano bootloader is bigger that of the Uno and sometimes incompatible with the watchdog timer, which could cause repeated system restarts.
At the electrical level, the nano 3.3v can be weak, especially on some clones.
Anyway, as already said, post your code. A wiring diagram would also help.