# Prompt Template Filler & Batch Expander

> Write a prompt once with placeholders, paste rows of data, and get every filled prompt back with its token count and cost.

This tool fills a prompt template from CSV or JSONL data, expanding one template plus N rows into N ready-to-send prompts. It supports Handlebars, Python-format, JavaScript-literal and shell placeholder syntax, refuses to silently blank a missing variable, and reports the token count and estimated cost of the whole batch before you send any of it.

**URL:** https://convertto.tech/t/prompt-template-generator
**Category:** AI & LLM Tools (https://convertto.tech/c/ai-tools)
**Privacy:** Runs entirely in the browser; no upload
**Cost:** Free, no sign-up
**Last updated:** 2026-08-01

## Key facts

- **Privacy:** Runs entirely in your browser — nothing is uploaded
- **Cost:** Free, unlimited, no sign-up

## How to use

1. Enter or paste your template.
2. Enter or paste your data.
3. Choose the placeholder syntax.
4. Choose the output as.
5. Turn "Fail on missing variables" on or off as needed.
6. Press Run, then download the result when it is ready.

## FAQ

### Why does it refuse to fill a missing variable?

Because a blank placeholder produces a prompt that still reads as valid English, gets a confident answer, and costs the same as a correct call. Failing loudly at template time is cheaper than discovering it in the output.

### Can I use this to build a fine-tuning file?

Yes — choose the JSONL output and each row becomes a request body with a single user message. Add the assistant side with the dataset converter.

## Related tools

- [Context Window Calculator](https://convertto.tech/t/context-window-calculator): Paste a document and see which models it fits inside, how much of each window it fills, and what is left for the reply.
- [Prompt Token Optimizer](https://convertto.tech/t/prompt-token-optimizer): Strip the padding out of a prompt — dead whitespace, boilerplate politeness, redundant framing — and see the tokens and money saved.
- [AI API Cost Calculator](https://convertto.tech/t/ai-api-cost-calculator): Work out what a prompt costs per call, per day and per month, and compare the same workload across every major model.
- [LLM Model Comparison](https://convertto.tech/t/llm-model-comparison): Every current model side by side: price per million tokens, context window, max output, modalities and cache rates.
- [LLM Stream Parser](https://convertto.tech/t/llm-stream-parser): Paste a raw server-sent-event stream and get the reconstructed message, tool calls, usage and stop reason.
- [LLM Token Counter](https://convertto.tech/t/llm-token-counter): Count tokens with the real BPE vocabulary, see every token coloured in place, and compare the count across models.
- [Prompt Injection Sanitizer](https://convertto.tech/t/prompt-injection-sanitizer): Strip invisible carriers, neutralise instruction-like markup and fence untrusted content before you paste it into a prompt.
- [Temperature & Top-p Visualizer](https://convertto.tech/t/temperature-top-p-visualizer): Watch sampling parameters change which tokens can actually be chosen, on a real softmax over logits you supply.
- [Fine-Tuning Dataset Converter](https://convertto.tech/t/fine-tuning-dataset-converter): Convert training data between the six common chat formats, and validate the result against the rules the upload endpoints enforce.
