Black Lives Matter. Please consider donating to Black Girls Code today.

Dash DataTable - Export as CSV

Being able to export to CSV would be a lifesaver! Any ideas on how to do this?

This has been answered a few times in the forum - search “download CSV”:

It would be great to just have an optional parameter for the Dash DataTable to include a download to CSV link. The URI approach is most commonly used, but has a size limit and doesn’t work in old browsers like IE11. It seems like this approach from Flask works in IE11, although I’m not sure about the size limit: I don’t see an easy way to rig up a callback to use this approach, but I think it’s not too hard to implement as part of Dash DataTable. I could assist, if helpful.


Yeah, I think we’ll include this in our new version of the data table. Alternatively, there’s an issue about creating a first-class download component: