ListQ
Examples
open all close allBasic Examples (2)
ListQ gives True when the head of an expression is List:
ListQ[{a, b, c}]Head[{a, b, c}]ListQ gives False when the head of an expression is not List:
ListQ[h[a, b, c]]Head[h[a, b, c]]ListQ gives False on other array representations:
ListQ[SparseArray[{{1, 0}, {0, 1}}]]ListQ[QuantityArray[{10, 30}, "Meters"]]Properties & Relations (3)
ListQ is equivalent to MatchQ[#,_List]&:
listQ = MatchQ[#, _List]&;{ListQ[{a}], listQ[{a}]}{ListQ[f[1, 2]], listQ[f[1, 2]]}{ListQ[SparseArray[{0, 0, 1, 0}]], listQ[SparseArray[{0, 0, 1, 0}]]}VectorQ returns True for other 1D array representations:
With[{vector = SparseArray[{0, 0, 1, 0}]},
{ListQ[vector], VectorQ[vector]}]With[{vector = QuantityArray[{20, 50}, "Meters"]},
{ListQ[vector], VectorQ[vector]}]ListQ[list] is not affected by deeper levels of List:
ListQ[{a, {b}}]VectorQ[list] does not accept deeper levels of List:
VectorQ[{a, {b}}]Related Guides
History
Introduced in 1991 (2.0)
Text
Wolfram Research (1991), ListQ, Wolfram Language function, https://reference.wolfram.com/language/ref/ListQ.html.
CMS
Wolfram Language. 1991. "ListQ." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/ListQ.html.
APA
Wolfram Language. (1991). ListQ. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/ListQ.html
BibTeX
@misc{reference.wolfram_2026_listq, author="Wolfram Research", title="{ListQ}", year="1991", howpublished="\url{https://reference.wolfram.com/language/ref/ListQ.html}", note=[Accessed: 12-June-2026]}
BibLaTeX
@online{reference.wolfram_2026_listq, organization={Wolfram Research}, title={ListQ}, year={1991}, url={https://reference.wolfram.com/language/ref/ListQ.html}, note=[Accessed: 12-June-2026]}