--- title: "Publish Captured Data to an FTP Server – Mozenda" slug: "publish-data-to-an-ftp-server" description: "After an agent runs successfully, you can have the results delivered to an external server using file transfer protocol (FTP). Learn how to publish your captured data to an FTP server." tags: ["record", "share", "save", "store"] updated: 2025-03-06T09:04:30Z published: 2025-03-06T09:04:30Z canonical: "help.mozenda.com/publish-data-to-an-ftp-server" --- > ## Documentation Index > Fetch the complete documentation index at: https://help.mozenda.com/llms.txt > Use this file to discover all available pages before exploring further. # Publish data to an FTP server To publish your data to a server using FTP (and related file-transfer protocols): In the Web Console: 1. Select an agent or a collection. 2. Select ![Agent-List](https://cdn.document360.io/03076343-9561-4857-8a4e-9f3bfed20ced/Images/Documentation/Agent-List.png) . 3. Select **Publishing**. ![Publish data to s3 4](https://cdn.document360.io/03076343-9561-4857-8a4e-9f3bfed20ced/Images/Documentation/Publish%20data%20to%20s3%204.png) 1. Select **FTP** under **Publishing method**. 2. Choose an option under **File includes**. 3. Choose an option under **Managed view**. 4. Choose the **File format** you want to publish to the FTP server. 5. Choose **when** you want the data to be published. 6. Enter **Computer address**. - This is the address of the FTP server. This is an IP address or subdomain (e.g. ftp.yourcompany.com). 1. Optionally select ![](https://cdn.document360.io/03076343-9561-4857-8a4e-9f3bfed20ced/Images/Documentation/Settings.png) to enter additional FTP settings. 2. Select **TEST SETTINGS** to test the connection. 3. Select **SAVE & PUBLISH NOW** to publish the data immediately or select **SAVE** to publish later. ![z publish_data FTP.png](https://cdn.document360.io/03076343-9561-4857-8a4e-9f3bfed20ced/Images/Documentation/z%20publish_data%20FTP%281%29.png) Note If your FTP server has a firewall, whitelist the following external IP address range so Mozenda can publish to it: 64.19.202.254 ## Additional FTP Publishing Settings ### Computer address This can either be an IP address or a URL. An example would be customerdata.mozenda.com. | Setting | Description | | --- | --- | | Folder | The folder where you want to store the data. (This usually starts with a forward slash `/`). | | Username | Used to sign in and connect to the FTP site. | | Password | Used to sign in and connect to the FTP site. | | Port | The port that the system uses to connect to the FTP site. (The default is port 21.) | | Use passive transfer mode | Dependent on the FTP server’s configuration. | | Use a secure connection | Dependent on the FTP server’s configuration. | | Test FTP Settings | Check that the system can successfully connect and has the permissions to add new files. | ### What to include in the file This setting allows the user to choose the view to be published. The default will be the view that is currently selected in the agent or collection. ### Filename This allows the user to specify the name of the file that will be sent via FTP. If it is left blank the name of the file will be the Collection name and the view name in the format `%Collection Name%-%View Name%` If a file of the same name exists in the FTP destination directory, the existing file will be overwritten. Variables that you can use in your file names: | Format | Effect | | --- | --- | | %DateTime% | Inserts a *date* time value in the format of *YYYY-MM-DD-HHMMSS*. | | %Date% | Inserts a *date* value in the format of *YYYY-MM-DD*. | | %YYYY% | Inserts the current year in the format of *YYYY*. | | %MM% | Inserts the current month in the format *MM*. | | %DD% | Inserts the current day of the month in the file name. | | %CollectionName% | Inserts the name of the collection. | | %CollectionID% | Inserts the ID of the collection. | | %AgentID% | Inserts the ID of the agent (when applicable). | | %ViewName% | Inserts the name of the view. | | %ViewID% | Inserts the ID of the view. | An example of a file name that would use the `%DateTime%` variable is `CNN-%DateTime%`. The name of a CSV file published on 2019-01-18 would be **CNN-2019-01-18.csv**. ## Advanced FTP setup information ### Timeouts to be aware of Mozenda is configured with the following timeout periods: - 60 seconds for the “Test FTP Settings” button in publishing settings - 24 minutes (1440 seconds) for actual publishing ### Permissions on your host The FTP user provided to Mozenda must have Read and Write permission on the destination directory and all subdirectories. ### Certificates For a server to allow FTPS or SFTP connections, the server must be configured with a valid SSL keypair. The SSL certificate can be self-signed and does not need to be chained to a trusted certificate authority. ### Firewall rules Note that depending on your setup, you may have a firewall on the host server and on the router/NAT. Both need to be configured for things to work. #### FTP Active requires: - Inbound rule allowing TCP connections on port set in Mozenda publishing settings (usually 21). - Outbound rule allowing TCP connections on all ports. #### FTP Passive requires: - Inbound rule allowing TCP connections on the port set in Mozenda's publishing settings (usually 21). - Inbound rule allowing TCP connections on the port range specified in your server’s passive mode settings. #### FTPS Explicit requires: - Inbound rule allowing TCP connections on the port set in Mozenda's publishing settings (usually 21). - Inbound rule allowing TCP connections on the port range specified in your server’s passive mode settings. #### FTPS Implicit requires: - Inbound rule allowing TCP connections on port set in publishing settings (usually 990). - Inbound rule allowing TCP connections on port range specified in your server’s passive mode settings. #### SFTP - Inbound rule allowing TCP connections on port set in publishing settings (usually 22).