Import vs DirectQuery in Power BI: The Decision That Determines Your Report's Destiny
Introduction
Of all the architectural decisions in Power BI, Import vs DirectQuery has the highest long-term consequences. Get it wrong and you'll spend months fighting performance problems that no DAX optimization can fix. Get it right and your report architecture scales naturally with your data.
Most tutorials explain what each mode does. Few explain the tradeoffs honestly. This one does.
Core Concept: Two Fundamentally Different Architectures
Import Mode
Data is extracted from the source, compressed into VertiPaq's in-memory columnar store, and stored inside the .pbix file (or in the cloud dataset). When a visual renders, Power BI queries its own in-memory copy. Refresh is a batch process - typically scheduled hourly, daily, or triggered manually.
This is the default. This is what 90% of Power BI implementations should use.
DirectQuery Mode
No data is stored in Power BI. Every visual generates a query that is sent to the source database in real time. When a user clicks a slicer, Power BI sends a SQL (or equivalent) query to the source and waits for a response.
This sounds better. It usually isn't.
Real-World Application: When DirectQuery Goes Wrong
A fintech startup chose DirectQuery because their CFO wanted "real-time data." Their source was a PostgreSQL database with 80 million rows.
On day one: the report opened in 12 seconds. Acceptable.
After 3 months: 45 seconds.
After 6 months: 2-3 minutes.
After 1 year: the DBA added indexes specifically for Power BI queries because the dashboard was impacting production database performance.
The real-time requirement? The CFO checked the dashboard once a day in the morning. A scheduled Import refresh every 4 hours would have served them identically - with millisecond response times.
DirectQuery created a production database dependency, a performance ceiling, and an operational burden. Import mode, with a modest refresh schedule, would have been invisible.
Technical Deep Dive: The Tradeoff Matrix
| Dimension | Import | DirectQuery |
|---|---|---|
| Query speed | Milliseconds (in-memory) | Seconds to minutes (network + source DB) |
| Data freshness | As fresh as last refresh | Real-time |
| DAX support | Full DAX language | ~70% of DAX supported |
| Dataset size limit | 1 GB (Pro) / 100 GB (Premium) | Unlimited |
| Source database load | None after refresh | Every visual interaction |
| Offline availability | Yes (cached) | No |
| Time intelligence | Full (with Date table) | Limited |
| Calculated tables | Supported | Not supported |
The hidden cost of DirectQuery: DAX restrictions. Several DAX functions - SUMMARIZECOLUMNS with certain filters, calculated tables, many time intelligence patterns - don't work in DirectQuery. Senior developers who learn DAX in Import mode then inherit a DirectQuery model spend weeks discovering which patterns are unavailable.
When DirectQuery Is Actually the Right Answer
Despite the warnings, DirectQuery is the correct choice in specific scenarios:
- Data exceeds the Import size limit - datasets over 1 GB (or 100 GB in Premium) can't be fully imported
- Regulatory compliance requires no data copy - some industries prohibit storing data outside the source system
- Sub-minute freshness is genuinely required - trading floors, live operations dashboards
- Source data changes continuously - IoT sensor streams, live transaction feeds
In all other cases, Import with a scheduled refresh is almost always superior.
Composite Models: The Best of Both Worlds
Since Power BI Desktop 2.80, Composite Models allow mixing Import and DirectQuery tables in the same model. The pattern:
- Large, slow-changing dimension tables (Products, Customers, Geography) → Import
- Large, fast-changing fact tables → DirectQuery
- Small lookup tables → Import
This gives you real-time fact data (order status, live inventory) with fast filter performance from in-memory dimensions. The combination resolves most "I need real-time but Import is too slow" conflicts.
[Customers - Import] ──→ [Orders - DirectQuery] ←── [Products - Import]
↑
[Date Table - Import]
Common Mistakes
Choosing DirectQuery because it "sounds more advanced." DirectQuery is not more professional than Import. It is a specialized tool for specific constraints. Using it without those constraints is architectural debt.
Not testing DirectQuery performance under concurrent users. A DirectQuery report that opens in 4 seconds for one user may take 40 seconds for 20 concurrent users, because every user generates independent database queries. Import mode serves all users from the same in-memory cache.
Assuming DirectQuery bypasses the dataset size limit. The size limit applies to the model definition - relationships, measures, metadata. DirectQuery tables don't add to the size limit, but your model can still grow large from calculated tables, Import tables in composite models, and metadata.
Pro Tips / Industry Insight
The Aggregation Tables feature in Power BI (available in composite models) is the production pattern for large-scale DirectQuery: build pre-aggregated Import tables for the most common query patterns (daily totals, regional summaries), and fall back to DirectQuery only for granular drill-through. Power BI automatically routes queries to the aggregation table or the source based on granularity.
This is how enterprises like Walmart and HDFC Bank run Power BI over billion-row datasets - not pure Import, not pure DirectQuery, but a hybrid with aggregations.
Summary
Import mode is the correct default: fast, full DAX, predictable refresh cost. DirectQuery is for specific constraints - size limits, compliance, genuine real-time requirements. Composite models bridge the gap. The decision is architectural and expensive to change later - make it deliberately, with a clear understanding of the tradeoffs, before building anything.
Prove your understanding of Power BI architecture with a live DRI score at devwithdata.in.
Shashikant
· Founder, DevWithDataData professional and Power BI instructor. Building DevWithData to help analysts prove their skills, not just collect certificates.
Reading is not enough. Prove your skill.
DevWithData measures your actual ability with the Data Readiness Index. Stop reading — start practicing.
Continue Learning
Power BI Architecture Deep Dive: How Data Actually Moves From Source to Dashboard
Every mysterious bug in Power BI - wrong totals, slow reports, broken slicers - traces back to architecture. Understanding VertiPaq, the formula engine, and the data pipeline is how you stop guessing and start diagnosing.
5 min readData Modeling Principles in Power BI: Why Your Model Is More Important Than Your Measures
A bad data model makes every DAX measure harder to write, slower to run, and more likely to return wrong results. Star schema is not optional - it is the foundation every reliable report is built on.
4 min readPower BI Performance Optimization: Query Plans, Measure Design, and the Art of Making Reports Instant
A report that takes ten seconds to load is a report people stop using. Model design and DAX execution have 10x more impact than visual tweaks, yet most developers only optimize the visual layer.
4 min read