To exit Xshell, enter 'exit' at the prompt of the terminal session and then click Exit on the File menu.