Dash apps

PyCafe supports creating, running, editing, and sharing Dash applications directly in your browser. There’s no need for any installation; it works with just a single click.

Your first app

Go to our homepage at https://py.cafe/ and click the Dash tile:

dash-tile

Once the page is loaded, you should see an Editor and File Browser on the left, and Preview Browser on the right with the the Dash app in it:

dash-preview

You can see the Terminal on the bottom right where you print statements go.

Editing the app

You can edit app.py in the Editor, and work as your normally would with Dash.

Uploading an app.py

You may want to upload a local file from your computer if you already developed a dash app locally.

From the file browser, you can choose New fileUpload files to upload an existing app.py or other Python scripts or modules. You can even upload images, csv files or any file you need for your Dash application.

dash-upload

Sharing your dash app

Share app with code

If you are ready with your Dash app, you might want to share it with other people.

You can share the screen you are seeing, with the Editor and Preview Browser open, by going to the Share dialog. Click the Share button on the left, and you will see a dialog like this: dash-share

Click the “copy to clipboard” button , and paste the link in an email or document to share it with others.

Share as an app

If you want visitors to only see the app, and not the Editor or File Browser, select the “APP” tab in the Share dialog, and use that link instead.

dash-share

People who visit this link, will see just the Dash app, as shown below:

dash-share

Note: Visitors can still read your sourcecode, read more about how PyCafe works.

Embed in an iframe

It is also possible to embed you app into an existing web page using an iframe. Choose the “EMBED” tab in the Share dialog and copy the HTML snippet into your clipboard:

dash-share

You can now insert the HTML snippet into your website or blog post. The result should look like this:


Wrap up

Congratulations, you have successfully created your first Dash app on PyCafe. You can now share it with your friends, colleagues, or embed it on your website.

;;