Overview
If an image message sends successfully but doesn’t display, it’s usually a thumbnail error.
Solution
-
For mobile clients using IMKit, include the
content
(image base64) parameter when sending an image message. -
Ensure the base64 thumbnail meets these conditions:
- The thumbnail (
content
field) must be a base64 string in jpg format. - The base64 thumbnail must exclude any prefix.
- The base64 string size must stay under 80 KB.
- The thumbnail (
-
Check the docs: https://docs.rongcloud.io/web-imlib/message/send#image
Note: Use FileReader or canvas to compress the image and generate the base64 string.