YouTube thumbnail AI prompt with a title readable at phone size
Set the title's place and size in the prompt, then shrink the thumbnail to 168×94 with ImageMagick to see if the title still reads.
A thumbnail that looks fine at 1280×720 can turn into a smudge in a recommendation list. Usually the title is too long, or the food photo spills over it. Both can be fixed in the prompt before any image exists.
[1] Shorten the title first. Give the video title to Gemini and ask for short candidates.
Write 5 candidate lines of big thumbnail text for the YouTube video title below. Rules:- Each candidate is at most 3 words and at most 14 characters including spaces.- Do not add facts that are not in the video title (time, ingredients, results).- Answer only with one candidate per line in the form "candidate | characters". No other text. Video title: {video title}With 10-Minute Egg Fried Rice from One Bowl of Leftover Rice as the title:
Egg Fried Rice | 1410-Minute Rice | 14Leftover Rice | 13One Bowl Rice | 13Fried Rice | 10A second run returned the same five lines, and the counts were right. Count them yourself anyway: printf '%s' 'Egg Fried Rice' | wc -m. In a Korean run of the same prompt the second attempt appended a unit to every count (5자), so the format is not stable either; the reported count is not a check.
[2] Turn "big" into a number. Measure how wide the title is at a few sizes in a bold font. The font file is linked into the working folder.
$ for s in 60 80 100 120; do convert -size 1280x720 xc:white -font NotoSansCJK-Bold.ttc -fill black -pointsize $s -gravity west -annotate +40+0 "Egg Fried Rice" -trim -format "pt=$s text_bbox=%wx%h at168=%[fx:round(h*94/720)]px\n" info:; donept=60 text_bbox=409x64 at168=8pxpt=80 text_bbox=543x85 at168=11pxpt=100 text_bbox=679x106 at168=14pxpt=120 text_bbox=813x127 at168=17pxat168 is the text height after shrinking to 168×94. With a 40px margin, only 80pt keeps 14 characters inside the left half (640px), and 11px is small. Split it into two lines instead:
$ convert -size 1280x720 xc:white -font NotoSansCJK-Bold.ttc -fill black -pointsize 140 -gravity west -annotate +40+0 "Egg Fried\nRice" -trim -format "pt=140 two_lines bbox=%wx%h\n" info:pt=140 two_lines bbox=621x319The two lines are 621px wide, but with the 40px margin the right edge lands at 661px, 21px past the center line. Cut the margin or drop the size a little; each line is still taller than the single 120pt line.
[3] Write the image prompt. Google's Gemini image prompting tips split a prompt into subject, composition, action, location and style, and the same page admits the model struggles with aspect ratios and sometimes misspells words. So the composition is pinned to two halves, and the title is quoted exactly.
YouTube thumbnail, landscape 16:9.Composition: split the frame vertically in half. Close-up of {dish} in the right half only; the plate edge must not cross the center line.Left half: plain {background color} background, no pattern, props or shadows.Title: "{line 1}" over "{line 2}" in the middle of the left half, extra-bold sans-serif, {text color}. Text block about 40% of the frame height.No other text, logos or watermarks.Style: bright natural light, food photography, sharp focus.Google's Imagen prompt guide also recommends keeping in-image text to 25 characters or less and describing size in words.
[4] Check the ratio of what comes back. Writing "16:9" does not guarantee it. The output below is from the test image drawn in step [2].
$ identify -format "%f %wx%h ratio=%[fx:w/h]\n" thumb-en.pngthumb-en.png 1280x720 ratio=1.77778Anything other than 1.77778 means regenerate, or use the app's aspect ratio setting if it has one. YouTube Help recommends 16:9 with a minimum width of 640px.
[5] Shrink it and look at actual size.
$ convert thumb-en.png -resize 168x94 small.png$ convert thumb-en.png -resize 320x180 mid.pngCheck the sizes with identify small.png mid.png.
168×94 is not exactly 16:9, so ImageMagick keeps the ratio and returns 167×94. In the test images, 60pt was hard to read at that size, 80pt was readable but small, and 120pt ran into the plate.
What to inspect in the generated image
| Where it goes wrong | How to check | One-line prompt fix |
|---|---|---|
| Title misspelled or extra letters | Compare letter by letter at full size | Title text exactly "{title}", nothing else |
| Photo crosses the center and covers text | Last letter visible at 167×94 | Plate stays inside the right half with a margin |
| Title comes out small | at168 under about 14px | Restate size as a share of frame height |
| Square or portrait output | ratio from identify | Use the ratio setting, or regenerate |
| Pattern or props in the left half | Zoom into the left half | Put plain solid background earlier |
If the title keeps coming out wrong, leave text out of the image and add it in an editor. For how resize filters change quality, see comparing resize filters.