Hello,
Your pictures certainly contain EXIF orientation information. Which are not used or stripped while converting.
You could :
- use cwebp and add -metadata all as
Extra command line options
- use GraphicsMagic and add -auto-orient as
Extra command line options
This way, with cwebp, metadata are kept and your converted picture should be auto-rotated like the orginial and, with gm, converted picture will be rotated according to orientation metadata then metadata will be removed.
Just give it a try.
Hope it helps.