Skip to main content
If your team exchanges files through an SFTP server, you can import data directly from the server. You don’t need to download the files to your computer first, and you don’t need to write R script. This page shows how to import three monthly sales order CSV files (4,000 rows each) from an SFTP server and merge them into one data frame.

What the SFTP data source is

The SFTP data source imports files from an SFTP server. It has the following features.
  • You can import CSV (delimited text), Excel, and Parquet files.
  • You can authenticate with an SSH private key or a password.
  • Host keys verify that you are connecting to the right server.
  • You can import one file, or merge multiple files while importing.
  • You can update published data on a schedule. See “Update on a schedule” below.

What to prepare

Ask your SFTP server administrator for the following information. This page uses these example values. Use a private key file in OpenSSH format. You cannot use a PuTTY format (.ppk) file.

1. Create a connection

You create a connection the first time you import a file. After that, you can select the saved connection.
  1. Click the + ❶ next to “Data Frames” on the left.
  2. Select “File” ❷ from the menu. Click + next to Data Frames, then select File from the menu The “File Data Source” dialog opens.
  3. Click the “SFTP” tab ❶ at the top.
  4. Select “Text (CSV, Delimited)” ❷. Click the SFTP tab, then select Text (CSV, Delimited) The “SFTP” tab shows three types: Excel, Text (CSV, Delimited), and Parquet.
  5. The next dialog depends on whether you already have an SFTP connection. If you have none, the “Add Connection - SFTP” dialog opens automatically. Go to step 7.
  6. If you already have a connection, the “SFTP - Select CSV Files” dialog opens. Click “Add Connection” ❶ at the top of the dialog. Click Add Connection at the top of the SFTP - Select CSV Files dialog The “Add Connection - SFTP” dialog opens.
  7. Enter a clear name in “Connection Name” ❶. This page uses Sales Data SFTP. Enter Sales Data SFTP in Connection Name
  8. Enter sftp.example.com in “Host” ❶. Enter sftp.example.com in Host
  9. Enter 22 in “Port” ❶. Enter 22 in Port
  10. Enter sftp-user in “Username” ❶. Enter sftp-user in Username
  11. Check that “Authentication” is set to the default, “Private Key”.
  12. To connect with a password, select “Password” ❶ in “Authentication”. A “Password” field appears in place of “Private Key File” and “Passphrase”. Select Password in Authentication to show the Password field This page uses a private key, so switch back to “Private Key” and continue.
  13. Click “Select File…” ❶ under “Private Key File” and select your private key file. The path of the selected file appears to the right of the button. Select a file under Private Key File If the private key has a passphrase, enter it in “Passphrase”.
  14. Enter the path of the folder that holds your files in “Root Folder” ❶. In this example, it is /Users/Shared/sftp-demo-en. If you leave “Root Folder” empty, Exploratory uses the home directory. Enter a path in Root Folder Below it, the “Host Keys” section shows “No host key is set.” In the next section, you get the host key.

2. Check and save the host key

A host key verifies that you are connecting to the right server. Before you save the connection, get the server’s host key and check its fingerprint.
  1. Click “Get Host Key” ❶ in “Host Keys”. Click Get Host Key, then check the key type and fingerprint After Exploratory gets the key, it shows “Key Type” and “Fingerprint (SHA256)” ❷.
  2. Compare the fingerprint with the one your server administrator gave you. If they match, continue. If they don’t match, don’t save the connection. Ask your administrator.
  3. Click “Add” ❶ at the bottom of the dialog to save the connection. Click Add to save the connection If you haven’t fetched the host key, Exploratory shows “Get the host key first.” and doesn’t save the connection. The host key is saved as part of the connection.
  4. If you just created your first connection, the dialog for selecting files opens next. If you created the connection from “Add Connection”, the “Data Connections” list appears. Click the × ❶ at the top right to close it. Close the Data Connections list with the × at the top right

3. Select files and import

In this section, you merge the three CSV files in the orders folder and import them.
  1. Select the connection you created, “Sales Data SFTP”, from the “Connection” drop-down ❶. The contents of the root folder appear in the list. Select Sales Data SFTP from the Connection drop-down
  2. Click the orders ❶ folder to open it. Open the orders folder The three files in the orders folder appear. The three CSV files in the orders folder appear in the list
  3. If you have many files, type part of a file name in the “Search” ❶ box at the top right and press Enter to narrow the list. This page uses 2026_02. Type 2026_02 in the Search box at the top right The list shows only orders_2026_02.csv, which contains 2026_02. The search shows only orders_2026_02.csv
  4. Click the × ❶ in the search box to clear the search. Click the × in the search box to clear the search
  5. Select the check box ❶ in the list header to select all three files. Select the check box in the header to select all three files
  6. Click “Import & Merge” ❶. Click Import & Merge The “Import & Merge Text File Data” dialog opens and shows the names of the three files you selected. The Import & Merge Text File Data dialog shows the three selected file names To import only one file, select its check box and click “Import”.
  7. Check the file contents and columns in the preview. The first column, “id”, holds the name of the file each row came from. Settings such as character encoding and delimiter work the same way as when you import a local CSV file. Check the file contents and columns in the preview
  8. Click “Import” ❶. Click Import The “Create Data Frame” dialog opens.
  9. Enter orders_2026_q1 in “Name” ❶.
  10. Click “Create” ❷. Enter a name for the data frame, then click Create Exploratory creates the data frame.
  11. Check that “12,000 Rows 11 Columns” ❶ appears at the top of the data frame. The 4,000 rows from each of the three files are now in one data frame. The imported data frame shows 12,000 Rows 11 Columns You can use the file names in the “id” column to summarize or filter the data by file.

Update on a schedule

The SFTP data source can update published data on a schedule. For how to set up a schedule, see Manage Schedules.
  • For a connection that uses a private key, Exploratory encrypts the contents of the private key file and sends it with the data when you publish.
  • If Exploratory cannot read the private key file, it marks the data as not updatable.

If the SFTP server restricts source IP addresses

Scheduled updates connect to your SFTP server from Exploratory’s servers. If your SFTP server restricts source IP addresses, ask the SFTP server administrator.

Limits and notes

  • You cannot use a private key in PuTTY format (.ppk). In PuTTYgen, use “Export OpenSSH key” in the “Conversions” menu to convert it to OpenSSH format, then select the converted file.
  • If the curl package of your installed R doesn’t support SFTP, the import stops with the error “EXP-DATASRC-36”. Reinstall the R packages from “R Packages” in the menu that opens when you click the user area at the bottom left of the start screen.
  • If the server’s host key changes, it no longer matches the saved host key, and the import fails with the error “EXP-DATASRC-39”. If you changed the server’s key on purpose, open the connection settings and click “Get Host Key” to get it again. If you didn’t expect the change, ask the server administrator.
  • If authentication fails, you get the error “EXP-DATASRC-38”. Check the username, the password, or the private key file and passphrase.
  • If Exploratory cannot connect to the server, you get the error “EXP-DATASRC-41”. Check the host name and port, and check that the SFTP server allows connections from your IP address.