This little process will create a tarball from a specified directory, then transfer it via ssh and extract it on the fly. The advantage of this method is the tarball is never needed to be created, transferred and then extracted.
( tar -cf - ./ ) | ( ssh user@host 'mkdir test101 && cd test101 && tar -xvf -' )
Of course swap user and host for the proper username (on the host system) and replace the host with the “hostname” of the target machine.