Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
ALERT: QlikView server communication interruptions following Microsoft Windows Domain Controller security updates

App Performance Optimization - Best Practices for Qlik Developers

cancel
Showing results for 
Search instead for 
Did you mean: 
kallnascimento
Partner - Contributor III
Partner - Contributor III

App Performance Optimization - Best Practices for Qlik Developers

Last Update:

Apr 28, 2026 2:58:59 PM

Updated By:

kallnascimento

Created date:

Apr 28, 2026 2:15:00 PM

Slow dashboards frustrate users and erode trust in your data. Whether you are building on Qlik Sense or Qlik Cloud, performance issues rarely come from the platform itself, they almost always come from design decisions made during development. The good news is that most of them are preventable.

This article walks through five foundational best practices that will help you keep your Qlik applications fast, scalable, and responsive.

1. Limit the number of visualizations per sheet

Every chart, table, and KPI tile on a sheet consumes engine resources the moment the sheet is opened. Qlik calculates all visible objects simultaneously, which means a sheet with twenty charts will always be slower than one with five, even if the underlying data is the same.

A practical rule of thumb is to keep each sheet focused on a single analytical question. If you find yourself adding more and more charts to answer related questions, that is usually a sign that the content belongs on a separate sheet or in a drill-down structure. Master Visualizations and Container objects can also help you organize content without multiplying the engine workload.

Beyond raw performance, fewer visualizations per sheet also improve the user experience. A focused layout guides the reader's attention and reduces cognitive overload.

2. Avoid heavy calculations in the UI ‐ push logic to the script

Qlik offers two places where you can perform calculations: the load script (executed once at reload time) and the expression layer (executed every time a user makes a selection). Expressions that are complex, nested, or operate over large datasets can noticeably slow down chart rendering, especially in multi-user environments.

The general principle is simple: anything that does not need to react to user selections should be calculated in the script. Pre-aggregated fields, derived flags, date parts, and category labels are all good candidates for script-level computation. By the time the data reaches the engine, those values are already stored as simple fields, no runtime cost.

Reserve the expression layer for calculations that genuinely depend on the current selection context, such as dynamic comparisons, percentage-of-total measures, or period-over-period variance. If an expression starts to look like a nested IF inside an Aggr() inside a Sum(), that is a strong signal to move some of that logic upstream.

3. Use Set Analysis instead of complex IF conditions

A common pattern among developers new to Qlik is writing IF conditions inside aggregation expressions to filter data - for example,

Sum(If(Region = 'North', Sales))

While this works, it forces the engine to evaluate the condition row by row across the entire dataset before aggregating. On large tables, this becomes expensive very quickly.

Set Analysis is the correct tool for this job. An equivalent expression

Sum({<Region={'North'}>} Sales) 

Tells the engine exactly which records to include before it begins aggregating, making it significantly faster. Set Analysis also integrates naturally with Qlik's associative selection model, which IF-based filters do not always respect correctly.

Beyond performance, Set Analysis expressions tend to be easier to read and maintain once you are familiar with the syntax. They also unlock more advanced scenarios, such as comparing the current selection against a fixed reference period, without resorting to complex conditional logic.

4. Avoid high-cardinality fields in charts

Cardinality refers to the number of distinct values a field contains. A field like CustomerID or TransactionTimestamp can have millions of unique values, these are high-cardinality fields. Using them as dimensions in charts causes the engine to generate one data point per distinct value, which is both slow to calculate and impossible to interpret visually.

The solution is to aggregate or bucket these fields before they reach the chart layer. Timestamps should be broken into meaningful time parts ‐ year, quarter, month, week, or day - depending on the granularity your analysis requires. This is best done in the load script using functions like Year(), Month(), or Floor() to create derived date fields. For numeric identifiers, consider whether the analysis actually needs individual-level detail or whether a grouped summary is more appropriate.

As a general guideline, chart dimensions should have a manageable number of distinct values ‐ typically no more than a few hundred at most. If a dimension naturally has more, consider adding a filter pane so users can narrow the scope before the chart renders.

5. Use Aggr() wisely ‐ only when truly needed

Aggr() is one of Qlik's most powerful functions. It creates a virtual table of aggregated values grouped by one or more dimensions, which then serves as the input for an outer aggregation. This enables calculations that would otherwise be impossible in the expression layer, such as "average order value per customer."

However, Aggr() is also one of the most resource-intensive functions available. Every time it is evaluated, the engine constructs an in-memory virtual table, which adds significant overhead ‐ especially when the inner dimension has high cardinality or when Aggr() is nested or used across multiple charts on the same sheet.

Before reaching for Aggr(), ask whether the same result can be achieved in the load script. If you need the average order value per customer, pre-calculating it as a script-level field is almost always faster than computing it at runtime with Aggr(). Reserve Aggr() for scenarios where the result genuinely needs to respond to user selections in a way that cannot be pre-computed, for example, ranked comparisons or dynamic top-N calculations.

When Aggr() is the right tool, keep the inner dimension as low-cardinality as possible and avoid nesting multiple Aggr() calls inside each other.

Summary

Performance optimization in Qlik is largely about knowing where computation belongs. The script is your best ally; it runs once and stores results efficiently. The expression layer is powerful but expensive, so use it selectively. Keeping sheets focused, choosing Set Analysis over row-level IF conditions, controlling dimension cardinality, and using Aggr() only, when necessary, will collectively make a measurable difference in how your applications feel to end users.

These practices are not just about speed, they are also about building applications that scale gracefully as data volumes grow and user counts increase.

Know more:

Aggr - chart function | Qlik Cloud Help

Sum Script function | Qlik Cloud Help

Set analysis | Qlik Cloud Help

if Script and chart function | Qlik Cloud Help

FloorScript and chart function | Qlik Cloud Help

year Script and chart function | Qlik Cloud Help

month Script and chart function | Qlik Cloud Help

Labels (1)
Comments
priscilarubim
Partner - Creator
Partner - Creator

Great topic! This is something I'm always concerned about, and reading about best practices is always good. Thank you for sharing.

jeffersonshibuya
Partner - Contributor III
Partner - Contributor III

very interesting! Thank you

steveshaw
Partner - Contributor III
Partner - Contributor III

Great write up. Thanks.

ChaithraMahesh
Partner - Contributor II
Partner - Contributor II

Good detailing 

Contributors
Version history
Last update:
3 weeks ago
Updated by: