How to return to the GUI?

You can run the opposite command:

sudo service lightdm start

Press alt+ctrl+F1.

Login using your credentials. Type in:

sudo service lightdm start 

Then press alt+ctrl+F7.