Master Apache Superset dashboard exports: configure PDF/PNG exports, set up scheduled email delivery, and automate reporting for your analytics team.
Apache Superset provides native functionality to export dashboards and individual charts in multiple formats—PDF, PNG, and CSV—with the ability to schedule these exports for automated email delivery. For teams running production analytics at scale, this capability becomes essential infrastructure. Rather than asking stakeholders to log into dashboards daily, you can push curated insights directly to inboxes on a schedule that matches business rhythms: daily executive summaries, weekly team performance reviews, or monthly board-level KPI snapshots.
The export and scheduling system in Superset is built on two core components: the client-side rendering engine (which captures visual representations of dashboards) and the server-side scheduler (which orchestrates when and how exports are delivered). Understanding how these components interact—and where the constraints and opportunities lie—is critical for anyone implementing self-serve BI at scale.
When you export a dashboard in Superset, you're not simply taking a screenshot. The system re-renders the entire dashboard using a headless browser (typically Selenium with a Chrome/Chromium driver), which means the export captures the live state of your data at the moment the export runs. This approach ensures fidelity: fonts render correctly, colors display as intended, and interactive elements resolve to their final visual state. For organizations embedding analytics into products or distributing reports across departments, this level of consistency matters.
Before configuring exports and scheduled delivery, you need to verify that your Superset deployment has the necessary infrastructure in place. The export functionality depends on several system-level components that must be properly configured.
First, you'll need a headless browser driver. Most Superset installations use Selenium with Chrome or Chromium. If you're running Superset in Docker (which is common for managed deployments like those at D23), the browser driver is typically pre-installed in the base image. However, if you're running Superset on a bare server or custom container, you'll need to install Chromium and Selenium WebDriver yourself.
Second, the email delivery system requires SMTP configuration. Superset doesn't send emails directly; instead, it queues export jobs and relies on a message broker (Redis or RabbitMQ) and a worker process to handle the actual sending. This asynchronous architecture prevents long-running export jobs from blocking your web server. You'll need to configure SMTP credentials in your Superset environment variables, typically through settings like SMTP_HOST, SMTP_PORT, SMTP_USER, and SMTP_PASSWORD.
Third, you need a task queue worker. Superset uses Celery to manage background jobs. When you schedule an export or trigger an alert, Superset creates a task in Redis or RabbitMQ. A Celery worker process picks up that task and executes it. In production, you should run at least one dedicated worker process (or multiple workers for high-volume export scenarios). If workers aren't running, scheduled exports will queue indefinitely without executing.
Finally, ensure you have sufficient disk space for temporary files. During export, Superset creates temporary PNG or PDF files before sending them. These files are cleaned up after delivery, but a sudden spike in export requests can consume significant disk I/O and space. Monitor /tmp or your configured temporary directory.
For teams using managed Apache Superset platforms, these infrastructure components are typically pre-configured and maintained by the platform provider, eliminating the operational burden of managing Selenium, Redis, and Celery workers yourself.
Superset offers two primary methods for exporting dashboards: the UI-driven manual export (useful for ad-hoc reporting) and the programmatic API approach (essential for automation and integration).
The simplest approach is the built-in export button. When viewing a dashboard, users can click the three-dot menu and select "Download as Image" or "Download as PDF." This triggers an immediate export job that runs in the browser's background and downloads the file to the user's local machine.
However, this approach has limitations. It's synchronous from the user's perspective—the browser waits for the export to complete before offering the download. For large, complex dashboards with many charts and long-running queries, this can take 30 seconds to several minutes. Additionally, it's manual: each stakeholder must remember to download the report, and there's no audit trail of who accessed what data when.
For production use cases, the REST API is more flexible. Superset exposes endpoints that allow you to trigger exports programmatically. According to the official Apache Superset documentation on alerts and reports, you can construct API calls to generate and retrieve dashboard exports.
The typical workflow is:
Here's a conceptual example of how this might look in Python:
import requests
import time
# Authenticate
auth_response = requests.post(
'https://your-superset-instance.com/api/v1/security/login',
json={'username': 'your_user', 'password': 'your_password'}
)
access_token = auth_response.json()['access_token']
headers = {'Authorization': f'Bearer {access_token}'}
# Trigger export
export_response = requests.post(
'https://your-superset-instance.com/api/v1/dashboard/1/export',
headers=headers,
json={'file_format': 'pdf'}
)
job_id = export_response.json()['job_id']
# Poll for completion
while True:
status_response = requests.get(
f'https://your-superset-instance.com/api/v1/export_jobs/{job_id}',
headers=headers
)
if status_response.json()['status'] == 'completed':
break
time.sleep(5)
# Download file
file_response = requests.get(
f'https://your-superset-instance.com/api/v1/export_jobs/{job_id}/download',
headers=headers
)
with open('dashboard.pdf', 'wb') as f:
f.write(file_response.content)This approach allows you to integrate Superset exports into custom workflows: trigger exports when data updates, attach them to automated emails, or pipe them into document management systems.
For recurring reporting needs, manual exports are impractical. Superset's native scheduling system automates the entire process: generate the export on a schedule and deliver it directly to recipients' inboxes without any manual intervention.
Scheduled exports are configured through the "Alerts & Reports" feature in Superset. To set this up, navigate to the dashboard you want to export, click the three-dot menu, and select "Set up an alert or report." This opens a modal where you define:
Report Name and Description: A human-readable identifier for the scheduled task. Use clear naming conventions like "Weekly Sales Dashboard - Finance Team" so recipients and admins understand the purpose.
Schedule: Superset uses Cron syntax for scheduling. Common patterns include:
0 9 * * 1 (every Monday at 9 AM)0 8 * * * (every day at 8 AM)0 10 * * MON-FRI (weekdays at 10 AM)0 0 1 * * (first day of each month at midnight)Cron scheduling is powerful but requires precision. A single character out of place changes the execution time entirely. If you're unfamiliar with Cron syntax, use an online Cron expression generator to verify your schedule before saving.
Recipients: Email addresses that should receive the export. You can specify multiple recipients, and Superset will send each person a copy of the export. For large distribution lists, consider creating a mailing list in your email system and using the list's address here, rather than maintaining individual email addresses in Superset.
Format and Delivery Options: Choose whether to send PDF, PNG, or both. PDF is ideal for reports that will be printed or archived; PNG is better for dashboards that will be viewed on screens or embedded in Slack messages. You can also choose whether to include the dashboard description and chart titles in the export.
Timezone: Superset stores schedules in UTC by default, but you can specify a timezone for the schedule. This is critical if your recipients are distributed across time zones. A report scheduled for "9 AM" should be unambiguous about which timezone that refers to.
Once saved, the report enters the Superset scheduler. Behind the scenes, Superset's Celery workers pick up the scheduled task at the specified time, render the dashboard, and queue an email for delivery. According to discussions in the Apache Superset GitHub repository, the rendering process uses a headless browser to capture the dashboard's visual state, ensuring that the exported file matches what users see in the browser.
Choosing between PDF and PNG export formats depends on your use case and distribution channel.
PDF is the standard format for formal reports and archival. PDFs preserve layout, fonts, and colors consistently across devices and operating systems. They're suitable for:
However, PDFs have trade-offs. They're larger in file size than PNGs, which can be problematic if you're emailing dozens of dashboards daily. PDF rendering is also more resource-intensive on the server side, as it requires additional processing to convert the rendered HTML into PDF format.
Superset generates PDFs using a library like ReportLab or Puppeteer. The rendering engine takes a screenshot of the dashboard, then embeds that image in a PDF container with metadata. This approach ensures visual fidelity but means the PDF is essentially an image wrapped in a PDF shell—you can't select and copy text from the PDF, and searching is limited.
PNG is a raster image format that's lightweight, widely supported, and ideal for digital distribution. PNGs work well for:
PNGs are smaller than PDFs and render faster, making them suitable for high-frequency exports. However, they don't preserve metadata, and very large dashboards may result in very large PNG files (or require scrolling to view the full image).
According to the Open edX documentation on downloading reports, both PDF and PNG exports capture the dashboard as it appears at the moment of export, including all applied filters and drill-down selections. This means the export reflects the exact state of the data at that point in time.
Once you've configured a scheduled export, the email delivery system takes over. Superset handles the email composition and sending, but you need to ensure the underlying infrastructure is properly configured.
Superset requires SMTP credentials to send emails. In a typical setup, you'll configure these environment variables:
SMTP_HOST=smtp.gmail.com
SMTP_PORT=587
[email protected]
SMTP_PASSWORD=your-app-password
SMTP_USE_TLS=true
[email protected]
If you're using a corporate email system, your IT team can provide the correct SMTP server address, port, and authentication method. Many organizations use services like SendGrid or AWS SES for transactional email, which offer SMTP endpoints and better deliverability than consumer email providers.
Superset generates a default email message that includes:
You can customize the email message by editing the report configuration. Some teams add context like "This report reflects data as of [timestamp]" or "Questions? Contact [support email]" to help recipients understand the report's scope and how to get help.
For advanced customization, you might use Superset's template system or integrate with a tool like Zapier or Make to intercept the export and reformat the email before sending. However, this adds complexity and requires careful integration testing.
Superset maintains a log of all scheduled report executions. In the Superset admin panel, navigate to "Alerts & Reports" and select your report. You'll see a history of execution times, delivery status, and any error messages.
Common issues include:
Email Not Delivered: Check SMTP credentials and ensure your SMTP server isn't blocking outbound mail. Some corporate networks restrict SMTP to specific servers. Verify that the recipient email addresses are correct and that your email domain isn't on any blocklists.
Export Fails to Generate: This usually indicates that the Celery worker process isn't running or that the dashboard contains queries that time out. Check the worker logs and consider optimizing slow-running queries. You can also increase the export timeout in your Superset configuration.
Attachment Missing or Corrupted: Ensure the headless browser driver (Chromium/Chrome) is installed and accessible. Check disk space on the server; if /tmp is full, the export process will fail. Verify that temporary files are being cleaned up properly after delivery.
For teams managing their own Superset instances, the official Apache Superset documentation on alerts and reports provides detailed troubleshooting guidance. For managed platforms like D23, support teams can diagnose and resolve delivery issues without requiring access to server logs.
Beyond the built-in scheduling system, you can integrate Superset exports into more sophisticated workflows.
Superset's native scheduler runs on a fixed Cron schedule, but sometimes you want to export a dashboard only when specific data conditions are met. For example, you might want to email a sales dashboard only on days when revenue exceeds a threshold, or a data quality dashboard only when anomalies are detected.
To implement this, use Superset's API in conjunction with an external orchestration tool like Airflow or dbt. The workflow would be:
This approach requires more infrastructure but enables highly targeted reporting.
If you're embedding analytics into a SaaS product or internal tool, you might want to allow users to export dashboards directly from your application. Using the Superset API, you can:
This creates a seamless experience where users never leave your application to access reports. According to the Preset blog on setting up automated reports in Apache Superset, this pattern is increasingly common for teams building analytics-first products.
Some organizations need different formats for different audiences. For example, executives might prefer a one-page PDF summary, while analysts need detailed PNG exports of individual charts. You can:
This requires more maintenance but ensures each stakeholder receives the information in their preferred format.
As you scale your export and scheduling infrastructure, performance becomes critical. Large dashboards with many charts or complex queries can take minutes to export, and high-frequency schedules can overwhelm your system.
Exports are only as fast as the underlying queries. If a dashboard contains a chart that takes 30 seconds to load in the browser, the export will also take at least 30 seconds. To speed up exports:
Optimize query performance: Use database indexes, materialized views, and query caching to reduce query execution time. Consider pre-aggregating data for common report queries.
Limit chart complexity: Dashboards with 20+ charts take longer to export than those with 5-10 charts. Group related metrics into fewer, more focused charts.
Use caching: Superset's caching layer stores query results so that repeated queries (e.g., from scheduled exports) don't hit the database every time. Configure cache TTLs appropriately for your reporting schedule.
Filter data at query time: Rather than exporting a full dashboard and then filtering in the email, apply filters at the database level. This reduces the amount of data that needs to be rendered.
If you're running dozens of scheduled exports daily, you need sufficient Celery workers to handle the load. Each export job consumes CPU and memory, and blocking the queue with slow exports can delay other jobs.
Scaling strategies include:
Run multiple Celery workers: Deploy additional worker processes across multiple servers. Each worker can handle one export at a time, so N workers can handle N concurrent exports.
Use dedicated worker pools: Create separate Celery queues for different job types (exports vs. queries vs. alerts) and assign workers accordingly. This prevents long-running exports from blocking other critical tasks.
Implement job prioritization: Mark critical reports as high-priority so they're processed before lower-priority exports.
Monitor queue depth: Track how many export jobs are queued and waiting. If the queue consistently has 10+ pending jobs, you need more workers.
For teams without the operational expertise or infrastructure to manage this, D23's managed Apache Superset platform handles worker scaling automatically, ensuring exports complete reliably regardless of volume.
Scheduled exports contain sensitive data, so access control matters. Superset enforces role-based permissions: only users who can view a dashboard can schedule exports of that dashboard. However, once an export is scheduled, it runs as a service account with broader permissions.
This creates a potential security gap: if a user schedules an export to an external email address, they've effectively exfiltrated data from your Superset instance. To mitigate this:
Restrict email recipients: Configure Superset to only allow exports to email addresses within your organization's domain (e.g., @yourcompany.com).
Audit scheduled reports: Regularly review the list of scheduled exports and verify that they're going to intended recipients. Remove reports that are no longer needed.
Encrypt exports in transit: Ensure SMTP is configured to use TLS encryption so emails aren't transmitted in plaintext.
Implement data masking: If dashboards contain sensitive columns (like personally identifiable information), use Superset's masking features to redact those columns in exports while keeping them visible in the interactive dashboard.
Use time-limited access: For sensitive reports, consider scheduling exports to go to a shared mailbox rather than individuals, and implement mailbox retention policies so old reports are automatically deleted.
Refer to D23's privacy policy and terms of service for guidance on how managed platforms handle export security and data retention.
Even with proper configuration, export failures happen. Here's how to diagnose and resolve common issues.
If an export consistently fails with a timeout error, the dashboard is taking too long to render. Solutions include:
SUPERSET_WEBDRIVER_BASEURL_TIMEOUT or similar)If exports fail with errors related to Chromium or Selenium, the headless browser isn't working. Verify:
which chromium-browser or which google-chromeIf the export doesn't match what you see in the browser, check:
For SMTP errors, verify:
Check Superset logs for detailed SMTP error messages, which often indicate the specific problem (e.g., "relay not permitted", "invalid credentials").
How does Superset's export functionality compare to other BI platforms? Understanding the trade-offs helps you evaluate whether Superset is the right choice for your organization.
Looker and Tableau offer more sophisticated export options, including scheduled PDF reports with custom formatting, parameterized exports (e.g., one report per customer), and integration with enterprise email systems. However, they're significantly more expensive and require more operational overhead. According to the dbt blog on Apache Superset dashboard export, Superset's export functionality is simpler but sufficient for most teams, and the open-source nature means you can customize the export system to your needs.
Metabase has built-in scheduled email reports similar to Superset, but with less flexibility around customization and integration.
Power BI uses a different paradigm (subscriptions) but offers similar functionality: scheduled delivery of reports to inboxes.
For teams that need export functionality without the complexity and cost of enterprise BI platforms, Superset strikes a good balance between capability and simplicity. And for organizations that need expert support and managed infrastructure, D23 provides managed Apache Superset with expert data consulting, handling the operational complexity while you focus on insights.
As you implement scheduled exports, follow these best practices to ensure success:
1. Start Small: Begin with one or two critical reports to executives. Once you've validated the system, expand to more dashboards and recipients.
2. Document Your Schedules: Maintain a spreadsheet or wiki listing all scheduled exports, their purpose, recipients, and schedule. This helps with auditing and troubleshooting.
3. Test Before Going Live: Schedule a report to yourself first. Verify that the export looks correct, arrives on time, and the file opens properly before sending to stakeholders.
4. Set Clear Expectations: Tell recipients when they should expect reports and what to do if a report doesn't arrive. Provide a contact for questions.
5. Review and Retire Regularly: Quarterly, audit your scheduled reports. Remove any that are no longer needed to reduce system load.
6. Monitor Performance: Track export execution times and failure rates. If exports are consistently slow or failing, investigate and optimize.
7. Use Version Control for Dashboard Changes: If you modify a dashboard that has scheduled exports, test the export to ensure the changes didn't break the report.
Apache Superset's export and scheduling capabilities provide a powerful, cost-effective way to automate dashboard distribution. Whether you're sending daily executive summaries, weekly team reports, or monthly board decks, Superset can handle it with minimal configuration.
The key to success is understanding the underlying infrastructure—Celery workers, SMTP servers, headless browsers—and ensuring it's properly configured and monitored. For teams that want to avoid this operational burden, managed platforms like D23 provide pre-configured export systems with expert support.
Start by identifying your most critical reports, configure scheduled exports for those, and gradually expand as you build confidence in the system. With proper planning and monitoring, you can build a reliable, scalable reporting infrastructure that keeps stakeholders informed without manual effort.