com.fasterxml.jackson.databind.exc.MismatchedInputException: Cannot deserialize value of type `java.util.ArrayList` from Object value
Jackson found JSON whose shape doesn’t match the target Java type (object vs array, string vs number, missing constructor).
Cannot deserialize value of typeCannot construct instance of Meaning
Typical: the JSON is wrapped ({"data": [...]}) while you map to a List, a single value where a list is expected, or a class without a default constructor/creator.
Common causes
- JSON wrapper object around the array
- Single value instead of array
- No default constructor (records/immutable classes without creators)
- Empty body
⚡ Quick fix
- Map to a wrapper class or read the subtree
- Enable ACCEPT_SINGLE_VALUE_AS_ARRAY when appropriate
- Add a no-args constructor or @JsonCreator
Detailed fix by platform
Java
- java
JsonNode root = mapper.readTree(json); List<Item> items = mapper.convertValue(root.get("data"), new TypeReference<>() {});
How to diagnose
- Shape — What does the JSON look like at that path?
- Type — What type are you mapping to?
🔧 Still not fixed?
Many errors look alike. If the steps above didn’t solve it, one of these is probably what you’re facing:
Similar errors
Most viewed in Java
Other ways to find it
Where this error sits
Origin: Application & API. Errors that are often confused with or caused by this one (click to open):
🧠 Still stuck? Analyze your error
Paste the full message, response headers or stack trace — we'll detect the platform and point to the most likely cause.
💬 What worked for others
No tips yet — did something else fix this for you?
Share what worked for you
Tips are checked by an editor before they appear. Links are removed.
Report a correction or suggest an improvement
Last updated 13 Oct 2026