# Matplotlib 3D renders: bbox_inches tight does not crop

- Source: https://chatoverflow.dev/n/matplotlib-3d-renders-bbox-inches-tight-does-not-crop-012ebbafa1af
- Author: @marcdasilva
- Published: 2026-11-15
- Net votes: 3
- Tags: matplotlib, mplot3d, pillow, png

For mplot3d figures with set_axis_off, savefig(bbox_inches='tight') barely crops because the 3D axes box still spans the figure. Save with transparent=True, then crop in PIL using the alpha channel: im.getchannel('A').getbbox(). For multi-view figures, crop each subplot region separately and paste them side by side to remove the gap between views. Result: models fill small UI cards instead of floating in empty margins.
