In Splunk, forms refer to interactive dashboards that include input fields. These inputs allow users to:
Filter the data shown in charts and tables
Enter custom search parameters (like usernames, IPs, or keywords)
Select time ranges or categories
Control which panels are displayed or updated
Forms make dashboards dynamic and user-friendly, turning static views into powerful tools for investigation and monitoring.
Form inputs are placed in the form section of the dashboard XML and pass values to the search panels via tokens.
Splunk supports a variety of input controls for building flexible and responsive dashboards.
Free-text input from users
Useful for keyword searches, usernames, IPs, etc.
Example:
<input type="text" token="username">
<label>Enter Username</label>
</input>
User selects one option from a predefined or dynamic list
Can be populated from search results or static values
Example:
<input type="dropdown" token="status">
<label>Select Status</label>
<choice value="200">OK</choice>
<choice value="404">Not Found</choice>
</input>
Allow selecting multiple values
Good for multi-select filters (e.g., regions, categories)
Example:
<input type="checkbox" token="region">
<label>Select Region(s)</label>
<choice value="us">US</choice>
<choice value="eu">Europe</choice>
</input>
Let users choose a time range
Directly controls earliest and latest search parameters
Example:
<input type="time" token="time_range">
<label>Select Time Range</label>
</input>
Time pickers are essential in most dashboards for narrowing down search scope and improving performance.
Tokens are placeholders that get replaced with user input at runtime.
Syntax:
$token_name$
These tokens are used inside search queries to dynamically adjust based on user interaction.
<search>
<query>index=main status=$status$</query>
</search>
The $status$ token will be replaced by the value selected in the drop-down.
If the user selects 200, the query becomes:
index=main status=200
You can also use tokens in:
Chart titles
Conditional logic
Panel visibility
You can configure default values for any form input, ensuring that the dashboard loads with valid parameters even before any user interaction.
Example:
<input type="dropdown" token="status">
<default>200</default>
...
</input>
This helps:
Prevent empty results on initial load
Provide context to new users
Improve dashboard usability
Sometimes one input should be dependent on another — for example, a second drop-down should populate only after the first one is selected.
This can be done using search-driven inputs and token chaining.
Example:
<input type="dropdown" token="service">
<label>Select Service</label>
<choice value="web">Web</choice>
<choice value="db">Database</choice>
</input>
<input type="dropdown" token="endpoint">
<label>Select Endpoint</label>
<search>
<query>index=main service=$service$ | stats count by endpoint</query>
</search>
</input>
Here, the endpoint drop-down depends on the selected service.
| Feature | Description |
|---|---|
| Form Dashboard | Interactive dashboard that uses input fields |
| Text Box | User enters custom values |
| Drop-down Menu | User selects one value from a list |
| Checkboxes | User selects multiple values |
| Time Picker | Allows user-defined time filtering |
| Tokens | Dynamic values passed from inputs to search panels |
| Default Values | Predefined input values on dashboard load |
| Dependent Inputs | Inputs that update based on another input’s value |
<default> vs <initialValue>Splunk form inputs support two mechanisms to pre-populate values: <default> and <initialValue>. Understanding their difference is crucial for both UX design and exam accuracy.
<default>Applies persistently after refreshes
Resets the token to the default value on each load
Useful when you want the dashboard to always start in a known state
<initialValue>Only applies on first load
Once a user changes the input, the value is retained even across refreshes
More flexible for user-driven workflows
Example:
<input type="text" token="user">
<label>Enter Username</label>
<default>admin</default>
<initialValue>guest</initialValue>
</input>
First-time users will see "guest"
On reload, it reverts to "admin" unless user interaction occurred
Exam Tip: Expect scenario questions asking why a value "reverts" or "persists" across sessions.
Splunk dashboards use tokens to pass values between inputs, panels, and logic. It's important to distinguish between token types:
Triggered by inputs like drop-downs or text fields
Example: $user$ (from a username text input)
Triggered by user interactions with visualizations
Examples:
$click.value$: Value clicked in a chart
$row.status$: Field from a clicked table row
Accessible across the entire dashboard (not restricted to one panel)
Often set using <set token="token_name" scope="global">...</set>
These distinctions are useful when controlling token scope and behavior, especially across multiple panels or drilldown-linked dashboards.
dependsSplunk provides a native way to show or hide panels based on the presence or value of a token. This is done using the depends attribute.
<panel depends="$user$">
<title>Details for $user$</title>
<table>
<search>
<query>index=auth user="$user$"</query>
</search>
</table>
</panel>
The panel only appears if the $user$ token has a value
Useful for:
Drilldown response panels
Progressive disclosure (advanced filters)
Exam Tip: Scenario-based questions may ask how to hide/show panels based on input—depends="$token$" is the expected solution.
choice value vs label in InputsWhen defining drop-downs or checkboxes, both a label and a value can be specified.
value: The actual content assigned to the token (used in search logic)
label: The user-facing display text in the dashboard
<choice value="200">OK (200)</choice>
<choice value="404">Not Found (404)</choice>
If the user selects "Not Found (404)", the token will be set to "404".
Search queries use the value
UI elements display the label
Exam Tip: Questions may ask:
“What value is passed to the token when a drop-down is used?”
→ The correct answer is the value, not the label.
Always use default or initial values to avoid blank tokens at load time
Use field-based token chaining with drilldowns for dynamic dashboards
Design for token reset behavior to avoid stale values when switching contexts
Understanding forms in Splunk means more than just using inputs. It involves:
Managing token lifecycles and types
Configuring display vs logic values correctly
Controlling panel visibility through token states
Creating predictable, user-friendly, and testable interfaces
Mastery of these details not only improves exam performance but also leads to better real-world dashboard development.
What is the central idea behind tokens in Splunk forms?
Tokens hold values from user interaction and pass those values into searches, labels, links, or other dashboard behavior.
That makes tokens the bridge between inputs and dynamic content. If a user chooses a time range, host, or category, the token carries that selection into searches and display elements. The exam commonly tests this concept because forms are essentially token-driven dashboards. A frequent mistake is thinking the input itself changes the search automatically without considering the token binding. If the question mentions form inputs influencing panels, tokens are almost certainly involved.
Demand Score: 72
Exam Relevance Score: 95
Why do users struggle with multiselect inputs more than simple dropdowns?
Because multiselect values often require different token handling and query logic than single-value inputs.
A single dropdown can usually map directly to one token value, but multiselect inputs may need special formatting to work in searches or pass “all” behavior correctly. That is why users often encounter token formatting problems even when the UI looks fine. On the exam, if the requirement mentions one-or-many selections, recognize that token handling becomes more complex than a single-value input pattern.
Demand Score: 70
Exam Relevance Score: 89
What makes an input “cascading”?
A cascading input changes its available options or behavior based on the value selected in another input.
This is a core form-design concept because it creates context-sensitive user experiences. One token drives the next input, narrowing choices and improving relevance. The exam usually tests whether you understand the dependency pattern rather than the exact XML syntax. If the scenario says “populate the second dropdown based on the first selection,” cascading inputs are the intended idea.
Demand Score: 67
Exam Relevance Score: 91
Why do token filters matter in forms?
Because they help adapt token values into the format needed for display, search syntax, or downstream logic.
Not every token should be used raw. Sometimes it needs escaping, quoting, formatting, or transformation before being inserted into SPL or shown in a label. The exam objective here is understanding that tokens are dynamic values that may need controlled handling. If the scenario implies that a selected value must be shaped before use, token filters are relevant. The common mistake is dropping raw user input straight into a search where it behaves unexpectedly.
Demand Score: 64
Exam Relevance Score: 86