Example: Upload and Download Files with Plotly Dash =================================================== This example demonstrates uploading and downloading files to and from a Plotly Dash app. This example simply saves the files to disk and serves them back to user, but if you want to process uploaded files, try adapting the ``save_file()`` function in this example. Python Source Code ------------------ .. literalinclude:: dash_file_upload_download.py Deployment ---------- Assuming that you store this file as ``myapp.py`` to ``/project/myappdirectory`` in your project workspace, the settings you need to deploy this in Faculty are: * **Working Directory:** ``/project/myappdirectory`` * **Python Module:** ``myapp`` * **Python Object:** ``server`` (the name of the Flask object used by Dash) You can also follow the instructions in :ref:`developing_plotly_dash_apps` to run the app in development mode. Usage ----- The app provides a widget to upload files, and maintains a list of download links for previously uploaded files: .. image:: images/dash_file_upload_download.png Only files that fit in memory on the server you run your app on will work, however for most applications this will not be a problem.