November 27, 2026 Kath Nguyen

Published:

Blender Command Line Rendering (2026): Render Animations, Choose GPUs and Keep a Log

EXECUTIVE SUMMARYKey Takeaways: Blender command line rendering
Blender 5.2 LTS · Nov 2026

Blender command line rendering runs a .blend file without the interface, so a render server can work through frames while you watch the log.

  • Order: Blender executes arguments left to right. Set -o, -F, -s and -e before -a.
  • GPU: Cycles options go after --. --cycles-device accepts CPU, CUDA, OPTIX, HIP, ONEAPI and METAL.
  • Several GPUs: Start one process per card with CUDA_VISIBLE_DEVICES and give each one its own frames.
  • Checks: Send the console to a log, search it for errors, and count the frames on disk against the range.
  • On iRender: You install the Blender version you need on a Windows or Ubuntu server. iRender keeps your server image between sessions.

Blender command line rendering is the way render servers run Blender: one terminal command opens the .blend file in the background, renders the frames you name and writes them to disk. This guide covers Blender 5.2 LTS on Windows and Ubuntu. It explains the flags you need, how to pick OptiX GPUs, and how to prove that every frame was written.

Checked on 26 November 2026 against the Blender 5.2 LTS Manual (Command Line Arguments, GPU Rendering) and NVIDIA CUDA documentation. Disclosure: iRender publishes this guide and rents GPU servers for Blender; the commands and flag names come from those sources, and the session video is our own recording.

Quick answer. To render frames 1 to 250 on the GPU with no interface, run blender -b scene.blend -o //frames/shot_#### -F PNG -s 1 -e 250 -a -- --cycles-device OPTIX. Keep that order: output, format and range before -a, and Cycles options after --.

1. What does Blender command line rendering do?

Blender command line rendering starts Blender with -b (background mode), loads a .blend file and renders it with no window. The render engine is the same Cycles you use in the interface. Only the way you start it changes.

Blender command line rendering matters on a render server for three reasons. First, on older GPU generations a card cannot render and draw the interface at the same time, and the Blender Manual lists that as one reason Blender becomes unresponsive during GPU renders. Second, a command can be saved, repeated and scripted. Third, you can run several Blender processes on one machine, one per GPU.

2. Which flags do you need to render an animation?

Blender command line rendering for an animation uses a handful of the flags below. The rule that trips people up is order: the Blender Manual states that arguments are executed in the order they are given. So the output path, format and frame range must appear before -a starts the render.

FlagWhat it doesExample
-bRun in background, with no interface. The .blend path follows it.-b shot.blend
-oOutput path. // means next to the .blend; # characters become the zero-padded frame number.-o //frames/shot_####
-FFile format, such as PNG, OPEN_EXR or OPEN_EXR_MULTILAYER.-F OPEN_EXR
-xAdd the file extension to each name (1 = on).-x 1
-s / -eStart and end frame of the range.-s 1 -e 240
-aRender the frames from start to end.-a
-fRender one frame, a comma separated list (no spaces) or a range such as 1..10.-f 10
-ERender engine. -E help lists the engines.-E CYCLES
-PRun a Python script file before the next arguments.-P set_gpu.py
-y / -YEnable or disable auto-run Python scripts. Disabled is the default.-y
--Ends Blender's own arguments. Cycles options follow it.-- --cycles-device OPTIX

Sources: Blender Manual, Command Line Arguments (accessed 26 November 2026).

The figure below breaks one full command into those parts. Follow the numbers from 1 to 7 when you write your own.

iRender
Anatomy of a Blender render command
follow along
Terminal on the render server: one command, read left to right$blender-bshot.blend-o//frames/shot_####-FOPEN_EXR-s1-e240-a----cycles-deviceOPTIX>1Run with no interface-b, then the .blend file2Where frames are saved// = next to the .blend, #### = frame3File formatPNG, OPEN_EXR, OPEN_EXR_MULTILAYER4Frame range-s start, -e end5Render the rangecomes after 2, 3 and 46End of Blender argsCycles options follow7Cycles backendCPU, CUDA, OPTIX, HIP…Blender executes the arguments in the order you type them✓ Put output, format and frame range before -a, and Cycles options after --Order rule and option names from the Blender Manual, Command Line Arguments
flagvalue or pathstep number
Illustrative command; your paths will differ

How to read the figure. Part 1 starts Blender without an interface and loads shot.blend. Parts 2 and 3 set where frames go and in which format. Part 4 sets frames 1 to 240. Next, part 5, -a, renders that range, so it must come after parts 2 to 4. Finally, part 6, the double dash, ends Blender’s own arguments, and part 7 tells Cycles to use OptiX.

Step 1: Render on Windows with PowerShell

For Blender command line rendering on a Windows server, call blender.exe with its full path. The backtick at the end of a line continues the command in PowerShell. The last line sends all console output to a text file.

iRender
Render an animation from PowerShell (Windows)
powershell
1# Blender 5.2 LTS installed by you on the server
2$blender = "C:\Program Files\Blender Foundation\Blender 5.2\blender.exe"
3& $blender -b "D:\shot\shot.blend" `
4 -o "//frames/shot_####" -F OPEN_EXR -x 1 `
5 -s 1 -e 240 -a `
6 -- --cycles-device OPTIX --cycles-print-stats `
7 *> "D:\shot\render_log.txt"
Output, format and range come before -a.Blender Manual: Command Line Arguments

Step 2: Render on Ubuntu with bash

On Ubuntu, the Blender download from blender.org is a folder you extract. nohup and the final & keep the job running after you disconnect.

iRender
Render the same shot on Ubuntu and keep it running
bash
1# Blender extracted to your home folder
2BL=~/blender-5.2.0-linux-x64/blender # adjust to your folder
3nohup "$BL" -b ~/shot/shot.blend \
4 -o "//frames/shot_####" -F OPEN_EXR -x 1 \
5 -s 1 -e 240 -a \
6 -- --cycles-device OPTIX > ~/shot/render_log.txt 2>&1 &
nohup keeps the job alive after you disconnect.Blender Manual: Command Line Arguments

3. How do you choose OptiX and specific GPUs from the command line?

Use -- --cycles-device OPTIX to choose the backend. The Blender Manual lists CPU, CUDA, OPTIX, HIP, ONEAPI and METAL as valid values, and +CPU adds the processor, for example OPTIX+CPU. To limit a process to certain cards, set CUDA_VISIBLE_DEVICES before Blender starts.

Background mode reads the Cycles device settings saved in your preferences. A fresh install on a server has none. If you want full control, run the short script below with -P. It switches the backend to OptiX, ticks every OptiX device and sets the scene to GPU Compute. It also prints each device, so the log shows which cards were used.

iRender
set_gpu.py: switch on OptiX devices before the render
python
1import bpy
2prefs = bpy.context.preferences.addons["cycles"].preferences
3prefs.compute_device_type = "OPTIX"
4prefs.refresh_devices()
5for dev in prefs.devices:
6 dev.use = dev.type == "OPTIX"
7 print("Device:", dev.name, dev.type, "ON" if dev.use else "off")
8bpy.context.scene.cycles.device = "GPU"
Run it with -P set_gpu.py, placed before -a.Blender Python API: CyclesPreferences

A full Blender command line rendering call then reads blender -b shot.blend -P set_gpu.py -o //frames/shot_#### -F OPEN_EXR -s 1 -e 240 -a. The script must come before -a, for the same ordering reason as the output path.

Step 3: Run one Blender per GPU

On a multi-GPU server you can also start one Blender per card, each with its own block of frames. Our Blender Cycles multi-GPU guide explains the method, the memory rule and our measured results on 1, 2 and 4 RTX 5090. The loop below is the Ubuntu version of the same idea.

iRender
Ubuntu: one Blender per GPU, each on its own frames
bash
1BL=~/blender-5.2.0-linux-x64/blender # adjust to your folder
2export CUDA_DEVICE_ORDER=PCI_BUS_ID
3for gpu in 0 1 2 3; do
4 start=$((gpu * 60 + 1)); end=$((start + 59))
5 CUDA_VISIBLE_DEVICES=$gpu nohup "$BL" -b ~/shot/shot.blend \
6 -o "//frames/shot_####" -F OPEN_EXR -x 1 -s $start -e $end -a \
7 -- --cycles-device OPTIX > ~/shot/log_gpu$gpu.txt 2>&1 &
8done
Each process sees one card and renders 60 frames.NVIDIA CUDA env vars; Blender Manual

Each process sees one card through CUDA_VISIBLE_DEVICES, and every card still holds the whole scene. To spread frames over several servers instead, see Blender network rendering.

The session video below shows the same per-GPU split, set up from the Blender window, on 1, 2 and 4 RTX 5090.

4. How do you know every frame was rendered?

Blender command line rendering ends with two checks: read the log, then count the files. Search every log for errors first. --cycles-print-stats adds render memory and time statistics, which help when one frame is much slower than the rest.

iRender
Check the logs and the frame count
bash
1# look for errors in every log
2grep -iE "error|out of memory" ~/shot/log_gpu*.txt
3# count the files on disk
4ls ~/shot/frames/shot_*.exr | wc -l
The file count should match the frame range.Blender console output

The file count should match the frame range. If they do not, our sequence check guide covers missing and black frames in detail. Each card below maps a symptom to its cause and fix for the problems we see most often with command line jobs.

iRender
Blender command line render problemstroubleshoot
SYMPTOM 1

Frames land in /tmp or in the wrong folder

Cause-o was typed after -a, so the render started before the output path was set.
FixMove -o and -F in front of -a or -f. Start the path with // to save next to the .blend file.
SYMPTOM 2

The job renders on the CPU even though the server has GPUs

CauseThe scene device is CPU, or no GPU backend was set for this run.
FixAdd -- --cycles-device OPTIX at the end, or run a script with -P that sets the device to GPU.
SYMPTOM 3

Drivers or rig expressions do not move in the render

CauseBlender disables automatic Python execution by default (-Y).
FixIf you trust the file, add -y to enable auto-run Python scripts.
SYMPTOM 4

A Cycles option has no effect

CauseCycles options were placed before the -- separator.
FixPut --cycles-device and --cycles-print-stats after --, at the end of the command.
SYMPTOM 5

Two processes write the same frames

CauseTheir -s/-e ranges overlap.
FixGive every process its own range, or use Placeholders as in our network rendering guide.
SYMPTOM 6

Textures render pink on the server

CauseThe .blend file points to absolute paths that only exist on your PC.
FixMake paths relative or pack resources before you upload. See the pink textures guide.
Find the card that matches what you see.Blender Manual: Command Line Arguments; File Paths

Before a long Blender command line rendering job, run through this list. It sums up the rules above in the order you meet them.

ChecklistBefore you start a command line render
0 / 8 done
Tip: add --cycles-print-stats when one frame is much slower than the rest; it logs render memory and time.

Command line renders: SaaS or IaaS render farm?

A SaaS render farm builds the command for you. That suits a scene that is already packed and only needs a frame range. An IaaS server gives you the terminal itself. That suits jobs where you choose the Blender build, run your own Python script, or split frames across GPUs your own way. Check two things first: can you set the exact Blender version, and can you read the full log? Our SaaS vs IaaS render farm guide compares both models in more detail. The trade-off is setup: on IaaS you install Blender yourself and manage the server while it runs.

Blender Command Line Rendering FAQ

1. How do I render a Blender animation from the command line?

Run blender -b file.blend -o //frames/shot_#### -F PNG -s 1 -e 250 -a. The -b flag starts Blender without its interface. The output, format and frame range must come before -a, because Blender reads the arguments in order.

2. How do I render a single frame from the command line?

Use -f with the frame number, for example blender -b file.blend -o //test_#### -f 10. Blender also accepts a comma separated list with no spaces, or a range such as 1..10.

3. How do I make Blender use the GPU when rendering from the command line?

Add -- --cycles-device OPTIX (or CUDA) at the end of the command. Cycles options must follow the double dash. You can also run a short Python script with -P that enables the OptiX devices and sets the scene device to GPU.

4. Why does Blender save my command line render to the wrong folder?

Usually -o was placed after -a or -f. Blender had already started rendering with the output path stored in the file. Put -o first, and use // for a path relative to the .blend file.

5. Is command line rendering faster than rendering from the Blender interface?

The renderer is the same, so the samples take the same work. The interface no longer has to redraw, and you can run several processes on one machine. That is why render servers usually run Blender in background mode.

6. Can I render on several GPUs from the command line?

Yes. One process can use every enabled GPU, or you can start one process per GPU with CUDA_VISIBLE_DEVICES and give each one its own frame range. Each GPU must hold the whole scene, because GPU memory is not shared.

7. Does the Blender command line work the same on Windows and Linux?

The Blender arguments are the same. Only the shell differs: PowerShell uses a backtick to continue a line, while bash uses a backslash and nohup to keep a job running after you log out.

Render your Blender projects on iRender

iRender rents Windows and Ubuntu servers with 1, 2, 4 or 8 RTX 5090 or RTX 4090 cards. You install the Blender version your file needs, run your own command line, and iRender keeps your server image between sessions. Upload to iRender Drive is free, and billing stops when you shut the server down.

This quick start shows how to start a server and render Blender on it:

Accelerate your production pipeline with high-performance IaaS render farm services and dedicated bare-metal workstations powered by up to 8x NVIDIA GeForce RTX 5090 (32GB GDDR7), high-frequency AMD Ryzen™ Threadripper™ PRO processors, 256GB ECC RAM, and dedicated 2TB NVMe SSD storage tailored for your pipeline:
, , , , , , ,

Kath Nguyen

Kath Nguyen is part of iRender's customer support team, where she helps artists move Cinema 4D, Redshift and Blender projects onto multi-GPU servers. Since 2022 she has written more than 80 English guides for the iRender blog, mostly on Cinema 4D and Redshift, Blender, Octane and Unreal Engine; many are also published in Korean and Spanish.
Contact

iRENDER GPU

Render Farm Pricing
Quick Start
Multi-GPU Benchmarks
iRender GPU App
Blog
Documentation
The Render Farm
The Company
Terms & Conditions

INTEGRATIONS

Autodesk Maya
Blender
Cinema 4D
Houdini
Karma XPU
Lumion
KeyShot
Unreal Engine
Twinmotion
Redshift
Octane
And many more…

iRENDER TEAM

Elite support 7 days a week
SATURDAY – SUNDAY: 6:00 AM – 11:59 PM
(UTC+7)
Hotline: (+84) 912-785-500
Email: [email protected]
Address 1: 68 Circular Road #02-01, 049422, Singapore.
Address 2: No.22 Thanh Cong Street, Hanoi, Vietnam.

Contact
이 페이지는 한국어로도 제공됩니다. 한국어로 보기 →