---
title: "Generate Frontend Template Command"
manual: "Content Blocks"
version: "main"
permalink: "https://docs.typo3.org/permalink/friendsoftypo3/content-blocks:command-generate-frontend-template@main"
source: "Commands/GenerateFrontendTemplate/Index.rst"
rendered: "2026-09-22T14:15:39+00:00"
---

# Generate Frontend Template Command {#command-generate-frontend-template}

The command `content-blocks:generate:frontend-template` generates a
frontend Fluid template for the given Content Element Content Block and writes
it to the `templates/frontend.fluid.html` file inside the Content Block
directory. The file will not be overwritten unless `--force` is provided.

## Arguments {#arguments}

-   **content-block**

    -   *Required:* true
    -   *Type:* string

    The Content Block to generate the frontend template for (e.g. `vendor/name`).

## Options {#options}

-   **force**

    -   *Shortcut:* f
    -   *Type:* bool

    Override an existing frontend template file.

Generate a frontend template for Content Block `example/my-block`:

```bash
vendor/bin/typo3 content-blocks:generate:frontend example/my-block
```

Override an existing frontend template:

```bash
vendor/bin/typo3 content-blocks:generate:frontend example/my-block --force
```
