You can use AutoFit Row/AutoFit Column by the following way in Excel Online:
- assume that your data is like below:
- Select A to C Column as below:
- Now stay your mouse pointer over the column divider between A and B.
- It will auto fit column:
By this way you can also auto fit the row height.