Build or check a KoboldCpp launch command

Pick options grouped like the launcher's tabs and copy a ready command for Windows, Linux or macOS, or a .kcpps file; or paste any command to have old, renamed or risky flags fixed. Every option comes from the real flag list of KoboldCpp 1.124.2, and we checked the output against the real program.

Checked against KoboldCpp 1.124.2 · updated 13 Nov 2026
  • lab-lnx: Linux test VM · 4 vCPU · 15 GB · no GPU
How we test

Command and .kcpps builder

Build a launch command for your shell, or paste one to check it.

Runs in your browser. Nothing is uploaded.

Presets
Main options 13 flags
default none · since 1.33

Selects the NVIDIA CUDA backend (or hipBLAS/ROCm in ROCm builds). Optionally give a GPU index or 'all'; legacy sub-options (mmq/nommq/lowvram/rowsplit) are still parsed and translated into the newer flags.

default none · since 1.56

Selects the Vulkan backend, which works on NVIDIA, AMD and Intel GPUs. Optionally list device indices; leave empty to auto-detect.

default false · since 1.75

Forces CPU-only inference with no GPU backend. Replaces the old --noblas.

default none · since 1.41

Loads a .kcpps settings file (or .kcppt template, also from a URL). Anything you also pass on the command line wins over the file.

default 16384 · since 1.20

Maximum context window in tokens to allocate (256-524288). Bigger values need more RAM/VRAM; default 16384 in 1.124.

default -1 · since 1.23beta

How many model layers to offload to the GPU. -1 (default) turns on autofit; 0 keeps everything on the CPU.

default · since 1.0.8beta

IP address to bind the HTTP server to. Empty (default) listens on all interfaces; use 127.0.0.1 for local-only.

default false · since 1.10

Opens your web browser on the UI once the model has loaded.

default none · since 1.37

For CUDA/Vulkan multi-GPU: space-separated proportions for how much of the model each GPU gets, e.g. `7 3`.

default 2 · since 1.0.8beta

CPU threads used for generation. Default is computed from your physical core count (the value shown in --help is machine-specific).

default 5001 · since 1.0.8beta

TCP port for the web UI and all APIs. Default 5001.

default false · since 1.82

Prints the KoboldCpp version and exits.

default false · since 1.0.8beta

Hidden legacy flag: old way to disable BLAS; now mapped to --usecpu.

Advanced 92 flags
default false · since 1.122

Starts the bundled KoboldCpp Agent (tool-using assistant for code and tasks) in a new terminal window, or in the current one when combined with --cli. Forces Jinja and raises context/gen defaults.

default · since 1.123

Resumes a saved KoboldCpp Agent session from its JSON save file when the agent starts.

default · since 1.82

Prints metadata, tensor names and weight types of a GGUF or safetensors file, then exits.

default false · since 1.104

Forces automatic fitting of the model across GPU(s)/CPU (layers, MoE overrides, splits), overriding manual layer settings.

default 1024 · since 1.108

Spare VRAM in MB that autofit leaves free as a safety margin (default 1024).

default 512 · since 1.8

Logical batch size for prompt processing (default 512). Larger is faster but uses more memory; -1 turns batching off. Formerly --blasbatchsize.

default -1 · since 1.122

Physical micro-batch size inside each batch. -1 (default) means same as --batchsize; lower it to save memory.

default none · since 1.57

Runs a benchmark instead of starting the server; optionally appends results to a CSV file.

default 0 · since 1.19

Thread count used during batched prompt processing; defaults to the --threads value.

default AutoGuess · since 1.62

Instruct-template adapter (JSON file or bundled name such as ChatML, Llama-3) used to format /v1/chat/completions prompts. Default AutoGuess detects it from the model.

default false · since 1.87

Runs an interactive chat in the terminal with no HTTP server. With --agent, runs the agent in the same terminal.

default 0 · since 1.15

Extra diagnostic output: -1 quiet (used for Horde), 0 normal, 1 verbose, higher for more detail.

default 2048 · since 1.86.1

Tokens to generate when a request does not specify a length (default 2048). Most frontends send their own value.

default · since 1.106.1

llama.cpp-style comma-separated device list (e.g. Vulkan0,Vulkan1) that overrides the normal GPU selection.

default · since 1.107.2

Folder where models given as URLs are downloaded to and looked up in (default: working directory).

default 4 · since 1.79

Number of tokens the draft model proposes per step in speculative decoding (default 4).

default 999 · since 1.80

GPU layers for the draft model (default 999 = fully offloaded).

default none · since 1.80

Multi-GPU split ratios for the draft model; only applies when the main model is split with --tensor_split.

default · since 1.79

Small model with the same vocabulary as the main model, used for speculative decoding to speed up generation.

default false · since 1.91

Turns on classifier-free guidance so negative prompts work for text; costs speed and memory.

default · since 1.85.1

Writes the current arguments to a .kcpps file (then exits) for reuse with --config.

default · since 1.85.1

Writes the current arguments as a shareable .kcppt template with machine-specific settings stripped.

default false · since 1.80

Maximum-compatibility mode for very old CPUs (no AVX); implies --noavx2. Very slow.

default false · since 1.45

Windows only: brings the console window to the front on each new generation to avoid idle slowdowns.

default · since 1.105

JSON object of default generation fields added to API requests that don't set them, e.g. {"temperature":0.7}.

default false · since 1.105

Makes --gendefaults values override what clients send instead of only filling gaps.

default 0 · since 1.73

Hard cap on generated tokens for every request (0 = no cap). Formerly --promptlimit.

default false · since 1.18

Raises the process CPU priority. Experimental; can cause system lag.

default false · since 1.61.2

Skips optional files (LoRA, mmproj, etc.) that cannot be found instead of aborting.

default false · since 1.102

Uses the model's embedded Jinja chat template (including tool calls) for chat completions, falling back to KoboldCpp's universal formatting if it fails. Since 1.123 also covers the former --jinjatools.

default · since 1.111

Extra JSON variables passed into the Jinja template renderer (llama.cpp's --chat-template-kwargs).

default · since 1.112

Path to a custom .jinja chat template that replaces the model's own.

default default · since 1.114

Quick switch for thinking/reasoning in Jinja templates: default, true or false. Setting it enables Jinja.

default none · since 1.11

Applies a text LoRA (GGUF) on top of the base model.

default 1 · since 1.93

Strength multiplier for the text LoRA (default 1.0).

default false · since 1.100

Keeps the KV cache in system RAM instead of VRAM (llama.cpp -nkvo). Fits more layers but is slow.

default -1 · since 1.94

In multi-GPU setups, index of the GPU used as the main device (-1 = default).

default 32 · since 1.88

Largest HTTP request body accepted, in MB (default 32); bigger requests are dropped.

default · since 1.106

Path to a Claude-Desktop-format mcp.json listing MCP tool servers (HTTP or stdio) to expose to the UI and agent.

default · since 1.61

Multimodal projector GGUF that adds image (and for some models audio) understanding to a compatible text model.

default false · since 1.90

Keeps the vision/audio projector on the CPU even when the main model is on GPU.

default auto · since 1.124

Controls on-demand reading of large architecture-specific tensors (e.g. per-layer embeddings): auto (>4 GiB), on, or off.

default 0 · since 1.124

Experimental VRAM cache (MiB) for MoE experts that otherwise live on the CPU; use with --moecpu or --autofit.

default 0 · since 1.97

Keeps the MoE expert weights of the first N layers (all if no number) in system RAM, freeing VRAM for big MoE models.

default 0 · since 1.121

Like --moecpu but for dense FFN weights of the first N layers.

default -1 · since 1.80

Overrides how many experts are active per token in MoE models (-1 = model default).

default false · since 1.79

Hosts a shared Kobold Lite session that several users can join and edit together.

default false · since 1.59

Disables SSL certificate verification for outgoing connections (e.g. the Horde worker). Insecure.

default false · since 1.78

Disables fast-forwarding, so every prompt is fully reprocessed; also disables context shift.

default false · since 1.107

Turns off flash attention, which is on by default since 1.107.

default false · since 1.5

Uses the slower non-AVX2 library for older CPUs (with Vulkan if requested).

default false · since 1.86.1

Stops the BOS token being prepended to prompts. Rarely needed.

default false · since 1.113

CUDA only: disables quantized matrix-multiplication (MMQ) kernels.

default false · since 1.74

Starts the server/UI without loading any model (e.g. to use the UI with Horde or a remote API).

default false · since 1.48

Disables ContextShift (KV-cache shifting when the context is full).

default false · since 1.114

Uses a full-size KV cache instead of sliding-window attention on models that support SWA. Needed if you want context shifting on such models.

default · since 1.44

Shell command to run once the model has loaded (e.g. start a tunnel). Ignored when it comes from a config file unless --allow-config-onready is set.

default false · since 1.116

Lets configs loaded after launch (admin swaps) set --onready. Only for trusted configs.

default · since 1.89

Overrides GGUF metadata keys, format name=type:value, comma-separated (llama.cpp --override-kv).

default 0 · since 1.98

Pretends the model was trained on this context length when computing RoPE scaling.

default · since 1.89

Places tensors matching a regex on a chosen backend buffer (llama.cpp -ot), e.g. to push experts to CPU.

default 1 · since 1.113

Number of generation slots that can run at once (experimental continuous batching). Default 1.

default 0 · since 1.124

Total KV budget in tokens shared by all parallel slots; defaults to --contextsize.

default none · since 1.61

API key that clients must send to use text endpoints (image endpoints are not protected). Also settable via KCPP_PASSWORD.

default · since 1.49

Serves a saved story JSON at /api/extra/preloadstory so Kobold Lite opens with it.

default · since 1.73

Runs a single prompt, prints the reply to stdout and exits (can be combined with --benchmark).

default f16 · since 1.67

KV-cache data type: f16 (default), bf16, q8_0, q5_1 or q4_0. Quantizing saves memory; without flash attention only K is quantized. Old numeric values 0-3 still accepted.

default 10 · since 1.123

Maximum number of requests allowed to wait in the queue (default 10).

default false · since 1.51

Hides prompts and generated text from the console (auto-on for Horde workers).

default 0 · since 1.99

Per-IP rate limit: each IP may start a new generation only every N seconds (0 = off).

default default · since 1.115

Default reasoning effort for thinking models (none/low/medium/high/xhigh); API requests can override it.

default false · since 1.48

Downloads cloudflared and opens a trycloudflare.com tunnel so the instance is reachable from the internet without port forwarding.

default 0,10000 · since 1.36

Manual RoPE scaling: frequency scale then frequency base (e.g. 0.25 10000). Without it, scaling is set automatically.

default · since 1.85.1

Server-side save database (.jsondb) so users can save/load stories to the server.

default false · since 1.93

Lets a newly started instance on the same port shut this one down, avoiding port clashes.

default 0 · since 1.104

Keeps KV-cache snapshots in RAM (optionally N slots) so switching between chats avoids full reprocessing. Requires fast-forwarding.

default false · since 1.7

Legacy context-reuse trick that reserves part of the context; superseded by ContextShift and not recommended.

default layer · since 1.113

How the model is split across GPUs: layer (default) or tensor (experimental). 'row' is still accepted but, since row split was removed in v1.118, it prints a warning and is treated as tensor split (splitmode_choices_to_int @ v1.124.2).

default none · since 1.53

Serves HTTPS using an unencrypted certificate and key PEM file.

default 0 · since 1.112

Extra tokens of padding for the SWA KV cache, which controls how far you can rewind before forced reprocessing.

default · since 1.70

Extracts the bundled files of the single-file binary into a folder (for running from source/unpacked).

default false · since 1.115

Uses a model's built-in multi-token-prediction layers as the draft for speculative decoding, if present.

default false · since 1.18

Locks the model in RAM so the OS cannot swap it out.

default false · since 1.3

Memory-maps the model file instead of reading it fully. Off by default since 1.82.

default false · since 1.120

Loads GGUF files with direct I/O, which can speed up cold loads on some disks.

default 1024 · since 1.83

Maximum image resolution fed to the vision projector (512-2048, default 1024).

default -1 · since 1.112

Overrides the maximum number of embedding tokens per image (-1 = model default).

default -1 · since 1.112

Overrides the minimum number of embedding tokens per image (-1 = model default).

default false · since 1.81

Enables the built-in web search proxy (DuckDuckGo) used by Kobold Lite and the agent.

default false · since 1.75

Shows the GUI launcher even when a config was passed, pre-filled with those settings.

default false · since 1.15

Never shows the GUI launcher (headless start); overrides --showgui.

default false · since 1.4

Hidden legacy flag from when mmap was the default.

AI Horde worker 5 flags
default · since 1.65

Model name your AI Horde worker advertises.

default · since 1.65

Name of your AI Horde worker.

default · since 1.65

Your AI Horde API key; setting it (with names) starts the embedded Horde worker.

default 0 · since 1.65

Largest context your Horde worker accepts (0 = same as --contextsize).

default 0 · since 1.65

Most tokens your Horde worker will generate per job.

Image generation 23 flags
default · since 1.114

Audio VAE used by LTX 2.3 video generation (video with sound).

default 0 · since 1.65

Shared-server safety: caps image steps and size (optional max side length, min 512).

default 0 · since 1.94

Caps total image area (e.g. 640 allows 640x640 or 512x768) to limit memory use.

default · since 1.78

First CLIP text encoder file (e.g. CLIP-L) if not baked into the image model. Formerly --sdclipl.

default · since 1.78

Second CLIP encoder (e.g. CLIP-G) or tokenizer file. Formerly --sdclipg.

default none · since 1.114

Where image text encoders/LLM run: GPU index, main, or CPU (default CPU).

default off · since 1.98

Conv2D direct mode for image generation: off (default), vaeonly or full. May save memory or crash on some backends.

default false · since 1.98

Uses flash attention in image/video generation.

default none · since 1.66

Image LoRA files (or a folder for runtime LoRAs) to apply.

default 1 · since 1.66

Strength multiplier(s) for the image LoRAs.

default none · since 1.111

GPU (index, main or CPU) that holds the image-generation weights.

default · since 1.65

Image/video model (safetensors or GGUF) to enable image generation: SD1.5, SDXL, SD3, Flux, Qwen Image, WAN, etc.

default false · since 1.100

Keeps image weights in RAM and moves them to VRAM only when needed.

default · since 1.94

PhotoMaker model for face cloning with SDXL models.

default 0 · since 1.65

Quantize the image model on load to save memory: 0 off, 1 q8, 2 q4.

default · since 1.122

Text encoder or LLM used by newer image models (T5-XXL, Qwen, etc.). Replaces --sdt5xxl.

default 0 · since 1.65

CPU threads for image generation (default: same as --threads).

default 512 · since 1.94

Image size above which VAE decoding is tiled to save memory (default 512; 0 disables).

default · since 1.107

ESRGAN upscaler model for enlarging generated images.

default · since 1.66

Custom VAE that replaces the one inside the image model.

default false · since 1.66

Uses the bundled tiny TAESD VAE: very fast, also fixes broken VAEs.

default none · since 1.114

Where the image VAE runs: GPU index, main (default) or CPU.

default 0 · since 1.115

Caps VRAM use of image generation to this many MB.

Speech to text 1 flags
default · since 1.67

Whisper .bin model for speech-to-text, or a SheetSage2 GGUF for music-to-ABC transcription.

Text to speech 6 flags
default · since 1.82

Text-to-speech GGUF model (Kokoro, OuteTTS, Qwen3-TTS, Parler, Dia, etc.).

default · since 1.82

WavTokenizer/codec GGUF required by some TTS models (OuteTTS, Qwen3-TTS).

default false · since 1.82

Runs the TTS model on the GPU.

default 4096 · since 1.83

Maximum audio tokens generated per TTS request (default 4096).

default 0 · since 1.82

CPU threads for TTS (default: same as --threads).

default · since 1.109

Folder of reference voice samples for TTS voice cloning.

Music 5 flags
default · since 1.109

Music language model (ACE-Step LM or YuE2) for music generation.

default · since 1.109

Text embedding model used by music generation (e.g. Qwen3-Embedding-0.6B).

default · since 1.109

Music diffusion (DiT) model, e.g. ACE-Step v1.5 turbo.

default · since 1.109

Music VAE / audio decoder model.

default false · since 1.109

Unloads music models when not generating to save VRAM.

Embeddings 3 flags
default · since 1.87

GGUF embedding model to serve /v1/embeddings and /api/extra/embeddings.

default 4096 · since 1.93.2

Overrides the maximum context of the embeddings model.

default false · since 1.94

Offloads the embeddings model to the GPU.

RPC 6 flags
default disabled · since 1.114

RPC GPU sharing over the network: disabled, connect (use remote GPUs) or host (share yours).

default 5551 · since 1.114

Port the RPC server listens on in host mode (default 5551).

default 0.0.0.0 · since 1.114

IP the RPC server binds to in host mode (default 0.0.0.0).

default · since 1.114

Comma-separated devices exposed by the RPC host.

default · since 1.124

Host mode: folder where tensors sent by clients are cached so reloading the same model is faster. Never cleaned; trust all clients.

default · since 1.114

Connect mode: comma-separated host:port list of remote RPC servers.

Admin 9 flags
default false · since 1.83

Enables admin mode: models/configs can be unloaded and swapped at runtime from the UI or admin API.

default none · since 1.83

Password protecting admin functions (strongly advised on public instances). Also via KCPP_ADMINPASSWORD.

default · since 1.83

Folder of .kcpps/.kcppt/.gguf files that admin mode may switch between.

default 0 · since 1.110

Seconds of idleness after which the current model is unloaded automatically (0 = never).

default false · since 1.110

Reverse-proxy router that swaps to the model named in each OpenAI-API request, then answers it. Requires --admin.

default 600 · since 1.113

HTTP request timeout in seconds (default 600; 0 = library default).

default false · since 1.111

On top of router mode, automatically switches between the model types defined in one config (text, image, audio...) as requests arrive.

default 256 · since 1.122

In autoswap mode, model families up to this size (MB, default 256) stay loaded; only one larger family is resident at a time.

default · since 1.112

Base .kcpps applied during admin model swaps when no other base is chosen.

./koboldcpp-linux-x64
How this works

Options are generated from the flag list that KoboldCpp 1.124.2 itself reports, so the builder cannot invent a flag. The checker reads a pasted command the way a shell would (quotes, continuation lines), looks every flag up, and compares combinations against a short list of rules, each with its evidence below. Sharing a link puts your settings in the address; passwords and keys are left out of it.

Data: KoboldCpp 1.124.2 · 13 Nov 2026 · methodology

KoboldCpp command line: how to read the result

  • Where to run it. In a terminal opened in the folder that contains the KoboldCpp file. On Windows use the CMD or PowerShell tab that matches your terminal; the quoting differs.
  • Loading a .kcpps file. --config mysetup.kcpps, or give the file name as the only argument; on Windows a double-click works if the .kcpps association is set. The settings in the file are applied as if typed on the command line.
  • The labels. Error: the flag does not exist or a value is out of range. Renamed: an old name that still works, or one that does not, with the replacement. Removed: the flag is gone, drop it. Risky: it runs, but not as you may expect or not safely. Note: harmless advice.

Flags that changed name or disappeared

This is what old guides get wrong. The list is built from KoboldCpp’s own flag data and release notes; each current name links to the flag reference.

Flags that changed name or disappeared
--usecublas--usecuda1.96renamed
--usehipblas--usecuda1.87renamed
--blasbatchsize--batchsize1.101renamed
--promptlimit--genlimit1.99renamed
--noblas--usecpu1.75renamed
--sdclipl--sdclip11.100renamed
--sdclipg--sdclip21.100renamed
--sdt5xxl--sdllm1.122renamed
--stream—v1.0.8beta..v1.59.1 (deprecated earlier, removed after 1.59)removed
--psutil_set_threads—v1.1..v1.59.1removed
--useclblast—v1.5..v1.106.2 (CLBlast backend removed in v1.107)removed
--unbantokens—v1.13..v1.59.1removed
--usemirostat—v1.19..v1.59.1removed
--renamemodel—v1.27 only (replaced by --hordeconfig)removed
--bantokens—v1.34.2..v1.63 (removed in 1.64)removed
--linearrope—v1.35 only (replaced by --ropeconfig)removed

Risky combinations the checker warns about

  • --usecuda with the nocuda file risky

    The nocuda file has no CUDA. It does not stop with an error: it runs on the CPU with the GPU line still printed, or fails with a driver message. Choose --usevulkan or download the CUDA file.

    Evidence: F17, F02

  • --host 0.0.0.0 without --password risky

    Anyone who can reach this PC can use your model and open the web page. Set --password; it protects generation, not the web page itself.

    Evidence: F25

  • --remotetunnel without --password risky

    The tunnel gives your server a public address. Without --password anyone who finds the address can generate text. Set one.

    Evidence: F25

  • --quantkv with --noflashattention risky

    Without flash attention only the K cache is quantised, so you save less memory than --quantkv suggests.

    Evidence: upstream: --quantkv help text

  • --contextsize outside 256 to 524288 error

    KoboldCpp refuses a context size below 256 or above 524288 and exits before loading anything.

    Evidence: F22

  • --smartcontext info

    SmartContext is superseded by ContextShift and not recommended. Remove it.

    Evidence: upstream: --smartcontext help text

  • --flashattention info

    Flash attention has been on by default since 1.107, so this flag does nothing. Use --noflashattention only to turn it off.

    Evidence: F09

  • --usecpu with --gpulayers above 0 info

    --usecpu keeps everything on the CPU, so --gpulayers has no effect.

    Evidence: F17

  • --port outside 1 to 65535 error

    A port must be a number from 1 to 65535.

    Evidence: upstream: --port help text

  • --usevulkan with --usecuda risky

    These choose different backends. Use one.

    Evidence: upstream: backend flags

  • no --model and no --config info

    No model file is given. KoboldCpp opens the launcher window (or fails on a machine without one) instead of starting.

    Evidence: F18

What this tool assumes

  • Options come only from the 1.124.2 flag list; defaults shown are that version’s. A flag that is not in the list cannot be selected.
  • The .kcpps download holds only what you changed. We checked that KoboldCpp loads such a file with every other setting at its default, and gives the same settings as the command F76.
  • Old .kcpps keys such as usecublas and blasbatchsize are translated the way KoboldCpp itself translates them at load.
  • Program names are examples (koboldcpp.exe, ./koboldcpp-linux-x64); use the name of the file you downloaded. On the nocuda file --usecuda runs on the CPU F17.
  • Not built: RunPod, Docker and Colab outputs (we have not tested them yet), and older version lists.

Accuracy and our tests

  • Against the real program. Twenty configurations (eight presets and twelve more, including paths with spaces and a password with an apostrophe) were run through the real KoboldCpp 1.124.2 binary with --exportconfig: every setting we set came back, and the partial .kcpps we write gave exactly the same 160 exported settings as the command F76. Linux build only.
  • The checker. Thirty fixtures from old guides and real problems (renamed and removed flags, typos, out-of-range values, risky combinations, continuation lines, --flag=value) give the expected result.
  • Quoting. Paths with spaces, apostrophes, parentheses and non-ASCII characters are quoted for bash, CMD and PowerShell, and each command parses back to the same settings. We tested CMD and PowerShell by parsing our own output, not in a real Windows terminal yet.
  • Last passed: 14 November 2026.

Frequently asked questions

How do I run KoboldCpp from the command line?

Open a terminal in the folder with the file and run it with the model: koboldcpp.exe --model C:\Models\model.gguf on Windows, or ./koboldcpp-linux-x64 --model model.gguf on Linux. Add flags after the model. The builder above writes the command for your shell, including the quotes for paths with spaces.

How do I make a .kcpps file without the launcher?

Set your options in the builder and open the .kcpps tab. It writes only the settings you changed, and KoboldCpp fills in the rest with its defaults; we checked that against the real program. Save it and start KoboldCpp with --config and the file name.

Does --usecublas still work?

Yes, as an old name of --usecuda since 1.96, and the builder's checker tells you to use the new one. Older flags that were removed, such as --useclblast, no longer exist; the checker lists them.

How do I start KoboldCpp without the GUI on Linux?

Give it a model on the command line (or a .kcpps file with --config). Without any model it tries to open the launcher window, which fails on a machine with no display. The Linux tab and the .sh script in the builder start it directly.

What do I put in RunPod's or Docker's settings?

The settings for those services are not in this builder yet, because we have not tested them. For now use the Linux command or a .kcpps file, and see the cloud and Docker guides when they are published.