aspect_ratio field is required on every generation request. The supported set depends on the model.
| Aspect ratio | NanoBanana | NanoBanana 2 / Pro |
|---|---|---|
1:1 | ✅ | ✅ |
2:3 | ✅ | ✅ |
3:2 | ✅ | ✅ |
3:4 | ✅ | ✅ |
4:3 | ✅ | ✅ |
4:5 | ✅ | ✅ |
5:4 | ✅ | ✅ |
9:16 | ✅ | ✅ |
16:9 | ✅ | ✅ |
21:9 | ✅ | ✅ |
1:4 | ❌ | ✅ |
1:8 | ❌ | ✅ |
4:1 | ❌ | ✅ |
8:1 | ❌ | ✅ |
auto | ❌ | ✅ |
from_prompt | ✅ | ✅ |
Special values
Infer the ratio from the first input image. Image-to-image only, and not supported by NanoBanana.
Let the model choose the ratio based on the prompt.