TestData query editor
Instead of a traditional query language, the TestData data source uses scenarios to generate simulated data. Each scenario produces a different type of data suited for testing specific visualizations, behaviors, or edge cases. TestData includes 30 scenarios covering time series, logs, traces, graphs, streaming, and error simulation.
Use scenarios to:
- Prototype dashboards without connecting to a real data source.
- Reproduce bugs with controlled, deterministic data that other developers can replicate.
- Test panel behavior with edge cases like empty results, timestamps outside the visible range, or mixed data and errors.
- Validate alerting pipelines using predictable patterns that fire and resolve on a known schedule.
- Simulate streaming to verify how panels handle real-time data updates.
To build a query, select a scenario from the Scenario drop-down. The query editor updates to show fields specific to that scenario. Click Run queries or use the keyboard shortcut to execute.
Note
Some scenarios run entirely in the browser (Streaming Client, Grafana Live, Grafana API, Steps, No Data Points). These scenarios don’t send queries to the backend, which means they can’t be used with Grafana Alerting or in any context that requires server-side evaluation.
Scenario reference
The scenarios are organized into the following categories. Use the table below to find the right scenario for your use case.
Shared query options
Every scenario displays the Scenario drop-down. Most scenarios also show an Alias field and, when the scenario defines a default, a String Input field. Some scenarios expose additional shared controls. Scenario-specific options appear below these fields.
Data generation scenarios
These scenarios produce time-series data with configurable parameters.
Random Walk
Generates random walk time-series data. This is the default scenario.
Random Walk Table
Generates random walk data in table format with columns for Time, Value, Min, Max, Info, and State. The State column uses an enum field with values Unknown, Up, and Down. Optionally includes null values when withNil is enabled.
Random Walk (with error)
Generates random walk time-series data and also returns an error in the response. Use this to test how panels handle data responses that contain both data and errors.
Predictable Pulse
Generates a predictable pulse wave based on absolute time from the epoch, making it reproducible across runs.
The wave cycles at Step * (On Count + Off Count) seconds. Timestamps align evenly on the step interval.
With the defaults (Step=60, On Count=3, Off Count=3), the wave completes a full cycle every 6 minutes. The on value (2) holds for the first 3 data points, then the off value (1) holds for the next 3.
Predictable CSV Wave
Generates one or more predictable waves from CSV-defined values. Each wave cycles through its comma-separated values at a fixed time step.
Click the + button on the last wave row to add another wave. Click the - button on any other row to remove it.
For example, to create two overlapping waves for comparison:
- Wave 1: Values
0,1,2,3,4,5, Step60, Namerising - Wave 2: Values
5,4,3,2,1,0, Step60, Namefalling
Simulation
Runs a simulation engine that generates data continuously. Simulation supports streaming data through Grafana Live.
USA generated data
Generates data with US state dimensions. Useful for testing geo-map visualizations and multi-dimensional data.
Manual input scenarios
These scenarios let you provide your own data directly instead of generating it.
CSV Content
Provides a text editor where you paste or type CSV data directly. The first row is treated as headers. Use the Drop percent field to randomly exclude a percentage of data points.
For example, enter the following to create a time series with two value columns:
Time,Temperature,Humidity
2024-01-01 00:00:00,22.5,45
2024-01-01 01:00:00,21.8,48
2024-01-01 02:00:00,20.1,52Steps
Provides a CSV text area (the same editor as CSV Content) for defining step-function data. The default content is a, b, c. This scenario is handled entirely in the browser.
CSV File
Selects from a set of built-in CSV data files. Use the Drop percent field to randomly exclude a percentage of data points.
Available files:
flight_info_by_state.csvpopulation_by_state.csvgdp_per_capita.csvjs_libraries.csvohlc_dogecoin.csvweight_height.csvbrowser_marketshare.csvautomobiles.csv
CSV Metric Values
Generates time-series data from comma-separated values entered in the String Input field. Values are evenly distributed across the selected time range. Default: 1,20,90,30,5,0.
For example, with the default values and a 6-hour time range, the six values (1, 20, 90, 30, 5, 0) are spread across the range at equal intervals.
Raw Frames
Provides a JSON editor for defining data frames directly. The editor accepts the Grafana data frame JSON format and includes paste helpers for panel JSON and raw query results.
Load Apache Arrow Data
Loads data from a base64-encoded Apache Arrow payload entered in the String Input text area. Use this to test Arrow format rendering.
Table Static
Generates a static table with predefined columns: Time, Message, Description, and Value.
Visualization test scenarios
These scenarios generate data for testing specific visualization types.
Logs
Generates simulated log data with random log levels, container IDs, and hostnames.
Node Graph
Generates data for the Node Graph visualization.
Flame Graph
Generates data for the Flame Graph visualization.
Trace
Generates simulated distributed trace data.
Annotations
Generates synthetic annotation data points. These annotations are created entirely in the browser and are useful for testing how panels display annotation markers and overlays. They don’t query an external source or persist data.
For more information about annotations in Grafana, refer to Annotate visualizations.
Exponential heatmap bucket data
Generates heatmap data with exponentially distributed bucket boundaries (1, 2, 4, 8, 16, …). Use this to test heatmap panels with exponential distributions.
Linear heatmap bucket data
Generates heatmap data with linearly distributed bucket boundaries (0, 10, 20, 30, …). Use this to test heatmap panels with linear distributions.
Streaming scenarios
These scenarios produce real-time streaming data. Data updates continuously in the browser without requiring manual query execution.
Streaming Client
Generates streaming data directly from the browser client.
Additional fields depend on the selected type:
- Signal: Speed (ms), Spread, Noise, Bands.
- Logs, Traces, Watch: Speed (ms) only.
- Fetch: URL of a remote CSV endpoint to stream incrementally.
Grafana Live
Connects to a Grafana Live channel that streams random data from the server.
Data retrieval scenarios
These scenarios fetch data from internal Grafana endpoints.
Grafana API
Fetches data from internal Grafana API endpoints and returns the result as a data frame. This scenario runs in the browser.
Error and edge-case testing scenarios
These scenarios help test how Grafana handles errors, empty data, and slow responses.
Conditional Error
Produces an error or data depending on the String Input and Error type fields. When the String Input field is empty, the scenario triggers the selected error type. When the field contains CSV values (default: 1,20,90,30,5,0), it returns time-series data like the CSV Metric Values scenario, regardless of the error type.
To trigger an error, clear the String Input field and select the error type you want to test.
Error with source
Returns an error with a configurable source classification.
Use this to test how Grafana differentiates between plugin errors and downstream errors in alerting and error handling.
No Data Points
Returns an empty result with no data points. Use this to test how panels display when there’s no data.
Data points Outside Range
Returns a single data point with a timestamp one hour before the query time range. Use this to test how panels handle data outside the visible range.
Slow Query
Introduces a configurable delay before returning random walk data. Set the delay duration in the String Input field using Go duration syntax (for example, 5s, 1m, 500ms). Default: 5s.
Metadata scenarios
These scenarios return metadata rather than time-series data.
Query Metadata
Returns a table with query metadata including the current user’s username. Use this to verify that query context information is available.


