sdxl Dimensions
The sdxl Dimensions Node
- width
- height
Every SDXL workflow starts with the same two seconds of fumbling: "is it 896×1152 or 1152×896, and which one is portrait?" SDXLDimensions_simple (displayed as "sdxl Dimensions") exists to end that. It's a dropdown of the six resolutions SDXL was actually trained on, and it outputs the width and height as clean INTs.
That's the whole job, and honestly it's a job worth doing well. SDXL was trained on a fixed set of aspect ratios around a 1024px base - 1024×1024, 1152×896, 1216×832, 1344×768, 1536×640 and their rotations. Generate on one of those and you're in the model's comfort zone; wander off it and you get the stretched bodies and repeated patterns that fill every "why does my image look wrong?" thread. This node just keeps the list in front of you so you stop guessing.
How it works
There's no math happening. The six presets are hardcoded strings ("1024 x 1024", "896 x 1152", and so on), and the node splits them into two integers. The only logic is the order toggle: pick swapped (height,width) and it reverses them so you can flip a landscape composition to portrait without touching any wires downstream.
The inputs and outputs
Two inputs, both dropdowns:
- dimensions - the six trained resolutions. Pick one.
- order -
default (width,height)orswapped (height,width).
Two outputs: width and height, both INT. Wire them into EmptyLatentImage, your sampler's resolution inputs, or any other node that wants dimensions.
Where it fits
This is the pack's SDXL image node, and it shows its age in the best way - it's from the original "Better Image Dimensions" line that started back in mid-2024, before this repo got forked and pointed at Wan video. The BetterDimensions category (note: no _v2) is the giveaway. For still-image SDXL generation it's still exactly right, and it pairs nicely with the Dimensions by Ratio node if you want the same shape ideas in free-form form.
It is not for video. If you loaded this pack because you're generating Wan clips, the wan Dimensions and wan Dimensions 720 nodes are the ones with the presets that matter for that. This one only knows SDXL, by design - there's no custom-resolution mode here either. If you need to type in an arbitrary width and height and snap them to a ratio, that's Better Image Dimensions_v2's job, not this node's.
Install
Standard for this pack - and it's a feather-light one, a single Python file, no dependencies, no model files, nothing to download except the node itself.
Via ComfyUI Manager: search ComfyUI-Better-Dimensions-wan-v2, install, restart. Or manually:
cd ComfyUI/custom_nodes
git clone https://github.com/neo-editer/ComfyUI-Better-Dimensions-wan-v2
then do a full ComfyUI restart.
Heads-up on a stale-README trap: the repo's README is inherited from the original upstream and tells you to clone corbin-hayden13/ComfyUI-Better-Dimensions.git. That gets you the old pack - same family, no Wan nodes. Use the neo-editer URL above.
Verdict
Not flashy, doesn't need to be. If you generate SDXL images in ComfyUI more than once a month, this node pays for itself by making the trained-resolution list a two-click decision instead of a memory exercise.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| dimensions | COMBO | 6 options: 1024 x 1024, 896 x 1152, 832 x 1216, 768 x 1344, 640 x 1536, 1216 x 832 | |
| order | COMBO | 2 options: default (width,height), swapped (height,width) |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| width | INT | — |
| height | INT | — |