{"id":848,"date":"2023-01-26T02:15:34","date_gmt":"2023-01-26T02:15:34","guid":{"rendered":"https:\/\/formatswap.com\/blog\/?p=848"},"modified":"2023-02-04T00:15:38","modified_gmt":"2023-02-04T00:15:38","slug":"how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh","status":"publish","type":"post","link":"https:\/\/formatswap.com\/blog\/linux-tutorials\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\/","title":{"rendered":"How to Setup an SFTP Server on Ubuntu 22.04 using OpenSSH"},"content":{"rendered":"\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" width=\"1024\" height=\"576\" loading=\"lazy\" src=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/how-to-setup-sftp-linux-1024x576.jpg\" alt=\"sftp splash\" class=\"wp-image-897\" srcset=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/how-to-setup-sftp-linux-1024x576.jpg 1024w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/how-to-setup-sftp-linux-300x169.jpg 300w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/how-to-setup-sftp-linux-768x432.jpg 768w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/how-to-setup-sftp-linux-1536x864.jpg 1536w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/how-to-setup-sftp-linux.jpg 1920w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>In this article you will learn how to enable and connect to the SFTP server in OpenSSH. With SFTP <a href=\"https:\/\/www.google.com\/url?sa=t&amp;rct=j&amp;q=&amp;esrc=s&amp;source=web&amp;cd=&amp;cad=rja&amp;uact=8&amp;ved=2ahUKEwiPguzplOT8AhXeGDQIHcEoDgYQFnoECCoQAQ&amp;url=https%3A%2F%2Fen.wikipedia.org%2Fwiki%2FSFTP&amp;usg=AOvVaw0aR87fP16TMb5PNXN6C71c\">(Secure File Transfer Protocol)<\/a> you can easily transfer files over the internet using SSH. We will be using Ubuntu 22.04 for our server, however any version of Linux should work.<\/p>\n\n\n\n<p>This guide will use password authentication with IP firewall restriction. This will prevent anyone besides those who you want accessing the box via SSH or SFTP. If you want the highest level of security possible you will want to enable keys in OpenSSH before following this guide. Learn how to enable keys with our <a href=\"https:\/\/formatswap.com\/blog\/linux-tutorials\/how-to-setup-openssh-with-keys-on-ubuntu-22-04\/\">How to Setup OpenSSH with Keys on Ubuntu 22.04<\/a> tutorial.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">SFTP vs FTP<\/h2>\n\n\n\n<p>It is important to mention that SFTP is not the same as FTP. One of the main differences is while they both transfer files, only SFTP encrypts the data during transit. Another difference is FTP is unable to benefit from public key files for authentication. Using public keys with SFTP increases security by encrypting the transfer data stream. If your aim is security then it is highly recommended you use SFTP versus FTP. Now that I have described the differences lets move on to configuring and connecting to an SFTP server in OpenSSH.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Update and Upgrade Ubuntu<\/h2>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" width=\"1024\" height=\"645\" loading=\"lazy\" src=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/1-update-and-upgrade-linux-1024x645.jpg\" alt=\"update and upgrade ubuntu\" class=\"wp-image-876\" srcset=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/1-update-and-upgrade-linux-1024x645.jpg 1024w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/1-update-and-upgrade-linux-300x189.jpg 300w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/1-update-and-upgrade-linux-768x484.jpg 768w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/1-update-and-upgrade-linux.jpg 1168w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>The first thing you need to do is update and upgrade your Ubuntu installation. Open a terminal and type the following command. Afterwards press &#8220;Y&#8221; to confirm.<\/p>\n\n\n\n<pre class=\"wp-block-code has-vivid-cyan-blue-color has-black-background-color has-text-color has-background\"><code>sudo apt update &amp;&amp; sudo apt upgrade<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Install OpenSSH<\/h2>\n\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" width=\"1024\" height=\"102\" loading=\"lazy\" src=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/install-openssh.jpg\" alt=\"install open-ssh\" class=\"wp-image-944\" srcset=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/install-openssh.jpg 1024w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/install-openssh-300x30.jpg 300w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/install-openssh-768x77.jpg 768w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>After your system has finished updating you will need to install the OpenSSH server software. OpenSSH provides encrypted file transfer for file transfers and remote logins. Install the software using the apt command.<\/p>\n\n\n\n<pre class=\"wp-block-code has-vivid-cyan-blue-color has-black-background-color has-text-color has-background\"><code>sudo apt install openssh-server<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">View SSH Status<\/h2>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" width=\"1024\" height=\"642\" loading=\"lazy\" src=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/2-check-ssh-status-1024x642.jpg\" alt=\"view ssh status\" class=\"wp-image-877\" srcset=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/2-check-ssh-status-1024x642.jpg 1024w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/2-check-ssh-status-300x188.jpg 300w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/2-check-ssh-status-768x481.jpg 768w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/2-check-ssh-status.jpg 1170w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>Next you need to verify that OpenSSH is installed on your system and actively running. Use the below command and confirm that you see &#8220;active (running)&#8221; on the third line.<\/p>\n\n\n\n<pre class=\"wp-block-code has-vivid-cyan-blue-color has-black-background-color has-text-color has-background\"><code>sudo systemctl status ssh<\/code><\/pre>\n\n\n\n<p>If SSH does not show as active and running it may be disabled. Run the following command to enable and start the OpenSSH server.<\/p>\n\n\n\n<pre class=\"wp-block-code has-vivid-cyan-blue-color has-black-background-color has-text-color has-background\"><code>sudo systemctl enable ssh &amp;&amp; sudo systemctl start ssh<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Create New User<\/h2>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" width=\"1024\" height=\"640\" loading=\"lazy\" src=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/3-add-new-user-1024x640.jpg\" alt=\"create a new user\" class=\"wp-image-878\" srcset=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/3-add-new-user-1024x640.jpg 1024w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/3-add-new-user-300x188.jpg 300w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/3-add-new-user-768x480.jpg 768w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/3-add-new-user.jpg 1171w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>Now you will need to create a new user for logging into the SFTP server. Run the adduser command then type a password. You can skip the other fields if you wish. Finally press &#8220;Y&#8221; to confirm.<\/p>\n\n\n\n<pre class=\"wp-block-code has-vivid-cyan-blue-color has-black-background-color has-text-color has-background\"><code>sudo adduser sftpuser<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Create New Group<\/h2>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" width=\"1024\" height=\"286\" loading=\"lazy\" src=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/4-add-sftp-group-1024x286.jpg\" alt=\"create a new group\" class=\"wp-image-879\" srcset=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/4-add-sftp-group-1024x286.jpg 1024w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/4-add-sftp-group-300x84.jpg 300w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/4-add-sftp-group-768x214.jpg 768w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/4-add-sftp-group.jpg 1171w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>Afterwards we will create a new group for our sftpuser. We will configure SSH to give SFTP access to any user in this group. Run the addgroup command to proceed.<\/p>\n\n\n\n<pre class=\"wp-block-code has-vivid-cyan-blue-color has-black-background-color has-text-color has-background\"><code>sudo addgroup sftpusers<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Add User to Group<\/h2>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" width=\"1024\" height=\"232\" loading=\"lazy\" src=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/5-add-user-to-group-1-1024x232.jpg\" alt=\"add user to group\" class=\"wp-image-892\" srcset=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/5-add-user-to-group-1-1024x232.jpg 1024w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/5-add-user-to-group-1-300x68.jpg 300w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/5-add-user-to-group-1-768x174.jpg 768w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/5-add-user-to-group-1.jpg 1147w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>Next we need to add the user to the new group. Run the usermod command to add the sftpuser to the sftpusers group.<\/p>\n\n\n\n<pre class=\"wp-block-code has-vivid-cyan-blue-color has-black-background-color has-text-color has-background\"><code>sudo usermod -a -G sftpusers sftpuser<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Change User&#8217;s Home Permissions<\/h2>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" width=\"1024\" height=\"272\" loading=\"lazy\" src=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/6-change-user-home-perms-1024x272.jpg\" alt=\"change users home permissions\" class=\"wp-image-881\" srcset=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/6-change-user-home-perms-1024x272.jpg 1024w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/6-change-user-home-perms-300x80.jpg 300w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/6-change-user-home-perms-768x204.jpg 768w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/6-change-user-home-perms.jpg 1170w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>Then we will set new permissions on the sftpuser&#8217;s home directory. This will allow the SFTP server to access these files. First execute the chown command followed by the chmod command. The sftpuser&#8217;s home will be the folder you access when you connect to the SFTP server. <\/p>\n\n\n\n<pre class=\"wp-block-code has-vivid-cyan-blue-color has-black-background-color has-text-color has-background\"><code>sudo chown root: \/home\/sftpuser<\/code><\/pre>\n\n\n\n<pre class=\"wp-block-code has-vivid-cyan-blue-color has-black-background-color has-text-color has-background\"><code>sudo chmod 777 \/home\/sftpuser<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Edit the SSH Config File<\/h2>\n\n\n\n<p>Next we need to edit the sshd_config file and edit a few lines. Open the configuration file using the nano text editor as shown below.<\/p>\n\n\n\n<pre class=\"wp-block-code has-vivid-cyan-blue-color has-black-background-color has-text-color has-background\"><code>sudo nano \/etc\/ssh\/sshd_config<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">Locate the Subsytem Line<\/h3>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" width=\"1024\" height=\"619\" loading=\"lazy\" src=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/9-locate-subsystem-line-1024x619.jpg\" alt=\"locate subsystem line\" class=\"wp-image-884\" srcset=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/9-locate-subsystem-line-1024x619.jpg 1024w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/9-locate-subsystem-line-300x181.jpg 300w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/9-locate-subsystem-line-768x464.jpg 768w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/9-locate-subsystem-line.jpg 1170w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>After you open the file scroll down and look for the Subsystem line. Once you locate the line comment it out using the &#8220;#&#8221; symbol as shown below.<\/p>\n\n\n\n<pre class=\"wp-block-code has-vivid-cyan-blue-color has-black-background-color has-text-color has-background\"><code>#Subsystem      sftp    \/usr\/lib\/openssh\/sftp-server<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">Add New Lines<\/h3>\n\n\n\n<figure class=\"wp-block-gallery has-nested-images columns-default is-cropped wp-block-gallery-1 is-layout-flex wp-block-gallery-is-layout-flex\">\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" width=\"1024\" height=\"702\" loading=\"lazy\" data-id=\"929\" src=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/10-add-new-lines-1-1024x702.jpg\" alt=\"edit lines\" class=\"wp-image-929\" srcset=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/10-add-new-lines-1-1024x702.jpg 1024w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/10-add-new-lines-1-300x206.jpg 300w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/10-add-new-lines-1-768x526.jpg 768w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/10-add-new-lines-1-1536x1053.jpg 1536w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/10-add-new-lines-1.jpg 1538w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n<\/figure>\n\n\n\n<p>Now that you have commented out the Subsystem line you need to add a few additional lines. Paste the following underneath the line you commented out. Your sshd_config file should match the screenshot above. After the lines have been added save and close the file using &#8220;Ctrl+X&#8221;.<\/p>\n\n\n\n<pre class=\"wp-block-code has-vivid-cyan-blue-color has-black-background-color has-text-color has-background\"><code>Subsystem sftp internal-sftp\n\nMatch Group sftpgroup\n     ChrootDirectory %h\n     X11Forwarding no\n     AllowTCPForwarding no<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Restart SSH<\/h2>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" width=\"1024\" height=\"148\" loading=\"lazy\" src=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/11-restart-ssh-1024x148.jpg\" alt=\"restart ssh\" class=\"wp-image-886\" srcset=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/11-restart-ssh-1024x148.jpg 1024w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/11-restart-ssh-300x43.jpg 300w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/11-restart-ssh-768x111.jpg 768w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/11-restart-ssh.jpg 1170w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>To apply our changes we will restart ssh. Use the following service command.<\/p>\n\n\n\n<pre class=\"wp-block-code has-vivid-cyan-blue-color has-black-background-color has-text-color has-background\"><code>sudo service ssh restart<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Configure the Firewall<\/h2>\n\n\n\n<p>The next step is to configure the firewall using UFW to control access to our SFTP server. Start by denying all incoming traffic, and allowing all outgoing.<\/p>\n\n\n\n<pre class=\"wp-block-code has-vivid-cyan-blue-color has-black-background-color has-text-color has-background\"><code>sudo ufw default deny incoming\nsudo ufw default allow outgoing<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">Allow SSH (All IP&#8217;s)<\/h3>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" width=\"1024\" height=\"69\" loading=\"lazy\" src=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/12-allow-ssh-ufw-1024x69.jpg\" alt=\"allow ssh\" class=\"wp-image-887\" srcset=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/12-allow-ssh-ufw-1024x69.jpg 1024w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/12-allow-ssh-ufw-300x20.jpg 300w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/12-allow-ssh-ufw-768x52.jpg 768w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/12-allow-ssh-ufw.jpg 1168w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>You have two options when allowing SSH through the firewall. You can either allow any IP to access port 22 (not recommended). Or you can only allow specific IP(s) through the firewall. I recommend the section option as it offers higher security. If you want to allow any IP run the following command.<\/p>\n\n\n\n<pre class=\"wp-block-code has-vivid-cyan-blue-color has-black-background-color has-text-color has-background\"><code>sudo ufw allow ssh<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">Allow SSH (Specific IP&#8217;s)<\/h3>\n\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" width=\"1025\" height=\"109\" loading=\"lazy\" src=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/enable-specfic-ip-ufw.jpg\" alt=\"allow specfic ip\" class=\"wp-image-935\" srcset=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/enable-specfic-ip-ufw.jpg 1025w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/enable-specfic-ip-ufw-300x32.jpg 300w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/enable-specfic-ip-ufw-768x82.jpg 768w\" sizes=\"auto, (max-width: 1025px) 100vw, 1025px\" \/><\/figure>\n\n\n\n<p>If you want to only allow specific IP&#8217;s to access the server run the following command for each IP you want to have access. You need to replace &#8220;IP-ADDRESS&#8221; with your own IP. This is highly recommended as it offers the highest level of security.<\/p>\n\n\n\n<pre class=\"wp-block-code has-vivid-cyan-blue-color has-black-background-color has-text-color has-background\"><code>sudo ufw allow from IP-ADDRESS to any port ssh<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">Enable UFW<\/h3>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" width=\"1024\" height=\"67\" loading=\"lazy\" src=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/13-enable-ufw-1024x67.jpg\" alt=\"enable ufw\" class=\"wp-image-888\" srcset=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/13-enable-ufw-1024x67.jpg 1024w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/13-enable-ufw-300x20.jpg 300w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/13-enable-ufw-768x51.jpg 768w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/13-enable-ufw.jpg 1170w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>After you have allow the IP&#8217;s (or everyone) who you want to have access you will need to enable UFW. Run the following command.<\/p>\n\n\n\n<pre class=\"wp-block-code has-vivid-cyan-blue-color has-black-background-color has-text-color has-background\"><code>sudo ufw enable<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">Check Firewall Status<\/h3>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" width=\"1024\" height=\"254\" loading=\"lazy\" src=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/14-check-ufw-status-1024x254.jpg\" alt=\"check firerwall status\" class=\"wp-image-889\" srcset=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/14-check-ufw-status-1024x254.jpg 1024w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/14-check-ufw-status-300x74.jpg 300w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/14-check-ufw-status-768x190.jpg 768w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/14-check-ufw-status.jpg 1170w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>The last step is to check the firewall status and verify your configuration. Check it using the ufw status command. If you allowed access to only specific IP&#8217;s you will see them in the &#8220;From&#8221; column.<\/p>\n\n\n\n<pre class=\"wp-block-code has-vivid-cyan-blue-color has-black-background-color has-text-color has-background\"><code>sudo ufw status<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Connecting to the SFTP Server<\/h2>\n\n\n\n<p>Finally we can test our connection to the SFTP server. The first thing you will need is a FTP client. I recommend downloading FileZilla. This is the software we will use in this tutorial. You can install it using the following apt command.<\/p>\n\n\n\n<pre class=\"wp-block-code has-vivid-cyan-blue-color has-black-background-color has-text-color has-background\"><code>sudo apt install filezilla<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">Edit Site List<\/h2>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" width=\"1024\" height=\"760\" loading=\"lazy\" src=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/14-open-site-manager-1024x760.jpg\" alt=\"edit filezilla site list\" class=\"wp-image-936\" srcset=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/14-open-site-manager-1024x760.jpg 1024w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/14-open-site-manager-300x223.jpg 300w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/14-open-site-manager-768x570.jpg 768w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/14-open-site-manager.jpg 1220w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>Open Filezilla and click on the site manager button in the upper left hand corner.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Add a New Site<\/h2>\n\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" width=\"997\" height=\"704\" loading=\"lazy\" src=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/15-click-new-site.jpg\" alt=\"add filezilla site\" class=\"wp-image-937\" srcset=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/15-click-new-site.jpg 997w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/15-click-new-site-300x212.jpg 300w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/15-click-new-site-768x542.jpg 768w\" sizes=\"auto, (max-width: 997px) 100vw, 997px\" \/><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Type Connection Information<\/h2>\n\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" width=\"1000\" height=\"715\" loading=\"lazy\" src=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/16-add-server-connection-details.jpg\" alt=\"add filezilla connection information\" class=\"wp-image-938\" srcset=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/16-add-server-connection-details.jpg 1000w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/16-add-server-connection-details-300x215.jpg 300w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/16-add-server-connection-details-768x549.jpg 768w\" sizes=\"auto, (max-width: 1000px) 100vw, 1000px\" \/><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Confirm Host Key Prompt<\/h2>\n\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" width=\"699\" height=\"331\" loading=\"lazy\" src=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/17-confirm-hostkey.jpg\" alt=\"confirm filezilla hostkey\" class=\"wp-image-939\" srcset=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/17-confirm-hostkey.jpg 699w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/17-confirm-hostkey-300x142.jpg 300w\" sizes=\"auto, (max-width: 699px) 100vw, 699px\" \/><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Verify Connection<\/h2>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" width=\"1024\" height=\"877\" loading=\"lazy\" src=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/18-verify-with-test-file-1024x877.jpg\" alt=\"verify filezilla connection\" class=\"wp-image-940\" srcset=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/18-verify-with-test-file-1024x877.jpg 1024w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/18-verify-with-test-file-300x257.jpg 300w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/18-verify-with-test-file-768x658.jpg 768w, https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/18-verify-with-test-file.jpg 1217w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Questions?<\/h2>\n\n\n\n<p>If you have any questions or comments feel free to leave them below.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Related Resources<\/h2>\n\n\n\n<p>View our <a href=\"https:\/\/formatswap.com\/blog\/linux-tutorials\/5-reasons-to-switch-from-windows-10-to-linux\/\">5 Reasons to Switch from Windows 10 to Linux<\/a><a href=\"https:\/\/formatswap.com\/blog\/machine-learning-tutorials\/how-to-create-a-deepfake-video-using-deepfacelab\/\">.<\/a><\/p>\n\n\n\n<p>Learn <a href=\"https:\/\/formatswap.com\/blog\/os-installs\/how-to-install-ubuntu-server-22-04-step-by-step\/\">How to Install Ubuntu Server 22.04 [Step by Step]<\/a>.<\/p>\n\n\n\n<p>Check out <a href=\"https:\/\/formatswap.com\/blog\/linux-tutorials\/how-to-setup-openssh-with-keys-on-ubuntu-22-04\/\">How to Setup OpenSSH with Keys on Ubuntu 22.04.<\/a><\/p>\n\n\n\n<p>View our <a href=\"https:\/\/formatswap.com\/blog\/linux-tutorials\/how-to-mount-an-smb-samba-share-in-linux-with-cifs-utils\/\">How to Mount an SMB (Samba) Share in Linux with cifs-utils<\/a> tutorial.<\/p>\n\n\n\n<p>Learn <a href=\"https:\/\/formatswap.com\/blog\/linux-tutorials\/how-to-use-the-alias-command-in-linux\/\">How to Use the Alias Command in Linux<\/a>.<\/p>\n\n\n\n<p>View all of our available online tools and converters at <a href=\"https:\/\/formatswap.com\" target=\"_blank\" rel=\"noreferrer noopener\">Formatswap.com<\/a>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>In this article you will learn how to enable and connect to the SFTP server in OpenSSH. With SFTP (Secure File Transfer Protocol) you can easily transfer files over the internet using SSH. We will be using Ubuntu 22.04 for our server, however any version of Linux should work. This guide will use password authentication [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"nf_dc_page":"","pagelayer_contact_templates":[],"_pagelayer_content":"","footnotes":""},"categories":[4],"tags":[8,36,14],"class_list":["post-848","post","type-post","status-publish","format-standard","hentry","category-linux-tutorials","tag-linux","tag-network-share","tag-tutorial"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.5 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>How to Setup an SFTP Server on Ubuntu 22.04 using OpenSSH - Format Swap - Tech Tutorials<\/title>\n<meta name=\"description\" content=\"In this article you will learn how to enable and connect to the SFTP server in OpenSSH. Allows easy and secure transfer of files over SSH.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/formatswap.com\/blog\/linux-tutorials\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to Setup an SFTP Server on Ubuntu 22.04 using OpenSSH - Format Swap - Tech Tutorials\" \/>\n<meta property=\"og:description\" content=\"In this article you will learn how to enable and connect to the SFTP server in OpenSSH. Allows easy and secure transfer of files over SSH.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/formatswap.com\/blog\/linux-tutorials\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\/\" \/>\n<meta property=\"og:site_name\" content=\"Format Swap - Tech Tutorials\" \/>\n<meta property=\"article:published_time\" content=\"2023-01-26T02:15:34+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2023-02-04T00:15:38+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/how-to-setup-sftp-linux-1024x576.jpg\" \/>\n<meta name=\"author\" content=\"admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"9 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/linux-tutorials\\\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/linux-tutorials\\\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\\\/\"},\"author\":{\"name\":\"admin\",\"@id\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/#\\\/schema\\\/person\\\/3d01ee8e1e4f3718cfcc57eeb8ad6188\"},\"headline\":\"How to Setup an SFTP Server on Ubuntu 22.04 using OpenSSH\",\"datePublished\":\"2023-01-26T02:15:34+00:00\",\"dateModified\":\"2023-02-04T00:15:38+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/linux-tutorials\\\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\\\/\"},\"wordCount\":987,\"commentCount\":0,\"image\":{\"@id\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/linux-tutorials\\\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/wp-content\\\/uploads\\\/2023\\\/01\\\/how-to-setup-sftp-linux-1024x576.jpg\",\"keywords\":[\"linux\",\"network share\",\"tutorial\"],\"articleSection\":[\"Linux Tutorials\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/formatswap.com\\\/blog\\\/linux-tutorials\\\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/linux-tutorials\\\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\\\/\",\"url\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/linux-tutorials\\\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\\\/\",\"name\":\"How to Setup an SFTP Server on Ubuntu 22.04 using OpenSSH - Format Swap - Tech Tutorials\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/linux-tutorials\\\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/linux-tutorials\\\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/wp-content\\\/uploads\\\/2023\\\/01\\\/how-to-setup-sftp-linux-1024x576.jpg\",\"datePublished\":\"2023-01-26T02:15:34+00:00\",\"dateModified\":\"2023-02-04T00:15:38+00:00\",\"author\":{\"@id\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/#\\\/schema\\\/person\\\/3d01ee8e1e4f3718cfcc57eeb8ad6188\"},\"description\":\"In this article you will learn how to enable and connect to the SFTP server in OpenSSH. Allows easy and secure transfer of files over SSH.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/linux-tutorials\\\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/formatswap.com\\\/blog\\\/linux-tutorials\\\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/linux-tutorials\\\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\\\/#primaryimage\",\"url\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/wp-content\\\/uploads\\\/2023\\\/01\\\/how-to-setup-sftp-linux.jpg\",\"contentUrl\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/wp-content\\\/uploads\\\/2023\\\/01\\\/how-to-setup-sftp-linux.jpg\",\"width\":1920,\"height\":1080},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/linux-tutorials\\\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How to Setup an SFTP Server on Ubuntu 22.04 using OpenSSH\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/\",\"name\":\"Format Swap - Tech Tutorials\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/#\\\/schema\\\/person\\\/3d01ee8e1e4f3718cfcc57eeb8ad6188\",\"name\":\"admin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/55cb3548d8c931eac3f2facbca246c6bde86082f48ca304906d7da2214191b72?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/55cb3548d8c931eac3f2facbca246c6bde86082f48ca304906d7da2214191b72?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/55cb3548d8c931eac3f2facbca246c6bde86082f48ca304906d7da2214191b72?s=96&d=mm&r=g\",\"caption\":\"admin\"},\"sameAs\":[\"https:\\\/\\\/formatswap.com\\\/blog\",\"https:\\\/\\\/www.youtube.com\\\/channel\\\/UCsIPLkRPTbbTaT8YX0Dh2-A\"],\"url\":\"https:\\\/\\\/formatswap.com\\\/blog\\\/author\\\/admin\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How to Setup an SFTP Server on Ubuntu 22.04 using OpenSSH - Format Swap - Tech Tutorials","description":"In this article you will learn how to enable and connect to the SFTP server in OpenSSH. Allows easy and secure transfer of files over SSH.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/formatswap.com\/blog\/linux-tutorials\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\/","og_locale":"en_US","og_type":"article","og_title":"How to Setup an SFTP Server on Ubuntu 22.04 using OpenSSH - Format Swap - Tech Tutorials","og_description":"In this article you will learn how to enable and connect to the SFTP server in OpenSSH. Allows easy and secure transfer of files over SSH.","og_url":"https:\/\/formatswap.com\/blog\/linux-tutorials\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\/","og_site_name":"Format Swap - Tech Tutorials","article_published_time":"2023-01-26T02:15:34+00:00","article_modified_time":"2023-02-04T00:15:38+00:00","og_image":[{"url":"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/how-to-setup-sftp-linux-1024x576.jpg","type":"","width":"","height":""}],"author":"admin","twitter_card":"summary_large_image","twitter_misc":{"Written by":"admin","Est. reading time":"9 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/formatswap.com\/blog\/linux-tutorials\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\/#article","isPartOf":{"@id":"https:\/\/formatswap.com\/blog\/linux-tutorials\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\/"},"author":{"name":"admin","@id":"https:\/\/formatswap.com\/blog\/#\/schema\/person\/3d01ee8e1e4f3718cfcc57eeb8ad6188"},"headline":"How to Setup an SFTP Server on Ubuntu 22.04 using OpenSSH","datePublished":"2023-01-26T02:15:34+00:00","dateModified":"2023-02-04T00:15:38+00:00","mainEntityOfPage":{"@id":"https:\/\/formatswap.com\/blog\/linux-tutorials\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\/"},"wordCount":987,"commentCount":0,"image":{"@id":"https:\/\/formatswap.com\/blog\/linux-tutorials\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\/#primaryimage"},"thumbnailUrl":"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/how-to-setup-sftp-linux-1024x576.jpg","keywords":["linux","network share","tutorial"],"articleSection":["Linux Tutorials"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/formatswap.com\/blog\/linux-tutorials\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/formatswap.com\/blog\/linux-tutorials\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\/","url":"https:\/\/formatswap.com\/blog\/linux-tutorials\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\/","name":"How to Setup an SFTP Server on Ubuntu 22.04 using OpenSSH - Format Swap - Tech Tutorials","isPartOf":{"@id":"https:\/\/formatswap.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/formatswap.com\/blog\/linux-tutorials\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\/#primaryimage"},"image":{"@id":"https:\/\/formatswap.com\/blog\/linux-tutorials\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\/#primaryimage"},"thumbnailUrl":"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/how-to-setup-sftp-linux-1024x576.jpg","datePublished":"2023-01-26T02:15:34+00:00","dateModified":"2023-02-04T00:15:38+00:00","author":{"@id":"https:\/\/formatswap.com\/blog\/#\/schema\/person\/3d01ee8e1e4f3718cfcc57eeb8ad6188"},"description":"In this article you will learn how to enable and connect to the SFTP server in OpenSSH. Allows easy and secure transfer of files over SSH.","breadcrumb":{"@id":"https:\/\/formatswap.com\/blog\/linux-tutorials\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/formatswap.com\/blog\/linux-tutorials\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/formatswap.com\/blog\/linux-tutorials\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\/#primaryimage","url":"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/how-to-setup-sftp-linux.jpg","contentUrl":"https:\/\/formatswap.com\/blog\/wp-content\/uploads\/2023\/01\/how-to-setup-sftp-linux.jpg","width":1920,"height":1080},{"@type":"BreadcrumbList","@id":"https:\/\/formatswap.com\/blog\/linux-tutorials\/how-to-setup-an-sftp-server-on-ubuntu-22-04-using-openssh\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/formatswap.com\/blog\/"},{"@type":"ListItem","position":2,"name":"How to Setup an SFTP Server on Ubuntu 22.04 using OpenSSH"}]},{"@type":"WebSite","@id":"https:\/\/formatswap.com\/blog\/#website","url":"https:\/\/formatswap.com\/blog\/","name":"Format Swap - Tech Tutorials","description":"","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/formatswap.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/formatswap.com\/blog\/#\/schema\/person\/3d01ee8e1e4f3718cfcc57eeb8ad6188","name":"admin","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/55cb3548d8c931eac3f2facbca246c6bde86082f48ca304906d7da2214191b72?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/55cb3548d8c931eac3f2facbca246c6bde86082f48ca304906d7da2214191b72?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/55cb3548d8c931eac3f2facbca246c6bde86082f48ca304906d7da2214191b72?s=96&d=mm&r=g","caption":"admin"},"sameAs":["https:\/\/formatswap.com\/blog","https:\/\/www.youtube.com\/channel\/UCsIPLkRPTbbTaT8YX0Dh2-A"],"url":"https:\/\/formatswap.com\/blog\/author\/admin\/"}]}},"_links":{"self":[{"href":"https:\/\/formatswap.com\/blog\/wp-json\/wp\/v2\/posts\/848","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/formatswap.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/formatswap.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/formatswap.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/formatswap.com\/blog\/wp-json\/wp\/v2\/comments?post=848"}],"version-history":[{"count":5,"href":"https:\/\/formatswap.com\/blog\/wp-json\/wp\/v2\/posts\/848\/revisions"}],"predecessor-version":[{"id":1032,"href":"https:\/\/formatswap.com\/blog\/wp-json\/wp\/v2\/posts\/848\/revisions\/1032"}],"wp:attachment":[{"href":"https:\/\/formatswap.com\/blog\/wp-json\/wp\/v2\/media?parent=848"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/formatswap.com\/blog\/wp-json\/wp\/v2\/categories?post=848"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/formatswap.com\/blog\/wp-json\/wp\/v2\/tags?post=848"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}