---
title: Examples
description: Write effective examples in documentation.
image: https://developers.cloudflare.com/cf-twitter-card.png
---

> Documentation Index  
> Fetch the complete documentation index at: https://developers.cloudflare.com/style-guide/llms.txt  
> Use this file to discover all available pages before exploring further.

[Skip to content](#%5Ftop) 

# Examples

## Definition

A code sample or line of text that shows the specific structure of a request/response, input/output, or value for UI/API elements

Note

If you are unsure about when to categorize something as an example or tutorial, remember:

Examples are a component attribute and are typically a snippet of code a user might copy and paste to run a task. Examples should not have multiple steps. A tutorial might contain an example, but an example will not contain a tutorial.

Tutorials are a content type, typically longer form, and contain multiple steps to help users connect products to real-world scenarios.

## Used in

[Tutorial](https://developers.cloudflare.com/style-guide/documentation-content-strategy/content-types/tutorial/), [How to](https://developers.cloudflare.com/style-guide/documentation-content-strategy/content-types/how-to/), [Reference](https://developers.cloudflare.com/style-guide/documentation-content-strategy/content-types/reference/)

## Structure

**Context**

Explain what the code sample does in a short sentence.

**Code blocks or snippets**

These could include:

* Example requests and responses
* Example inputs and outputs
* Field values for UI and/or API

## Additional information

[Code block guidelines](https://developers.cloudflare.com/style-guide/formatting/code-block-guidelines/)

## Requests/feedback

[https://github.com/cloudflare/cloudflare-docs/issues/150 ↗](https://github.com/cloudflare/cloudflare-docs/issues/150)

```json
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"item":{"@id":"/directory/","name":"Directory"}},{"@type":"ListItem","position":2,"item":{"@id":"/style-guide/","name":"Style Guide"}},{"@type":"ListItem","position":3,"item":{"@id":"/style-guide/documentation-content-strategy/","name":"Product docs content strategy"}},{"@type":"ListItem","position":4,"item":{"@id":"/style-guide/documentation-content-strategy/component-attributes/","name":"Component attributes"}},{"@type":"ListItem","position":5,"item":{"@id":"/style-guide/documentation-content-strategy/component-attributes/examples/","name":"Examples"}}]}
```
