---
description: Code examples showing how to use Containers with Workers for stateless routing, cron jobs, WebSockets, and more.
title: Examples
image: https://developers.cloudflare.com/og-docs.png
---

[Skip to content](#main-content)

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

# Examples

Last updated Aug 25, 2026|Copy as Markdown|[View as Markdown](https://4f1c5cd2.previews.developers.cloudflare.com/containers/examples/index.md)|[Agent setup](https://4f1c5cd2.previews.developers.cloudflare.com/agent-setup/)

Explore the following examples of Container functionality:

[**Mount R2 buckets with FUSE**Mount R2 buckets as filesystems using FUSE in Containers](https://4f1c5cd2.previews.developers.cloudflare.com/containers/examples/r2-fuse-mount/)

[**Static Frontend, Container Backend**A simple frontend app with a containerized backend](https://4f1c5cd2.previews.developers.cloudflare.com/containers/examples/container-backend/)

[**Cron Container**Running a container on a schedule using Cron Triggers](https://4f1c5cd2.previews.developers.cloudflare.com/containers/examples/cron/)

[**Using Durable Objects Directly**Various examples calling Containers directly from Durable Objects](https://4f1c5cd2.previews.developers.cloudflare.com/containers/examples/durable-object-interface/)

[**Env Vars and Secrets**Pass in environment variables and secrets to your container](https://4f1c5cd2.previews.developers.cloudflare.com/containers/examples/env-vars-and-secrets/)

[**Stateless Instances**Run multiple instances across Cloudflare's network](https://4f1c5cd2.previews.developers.cloudflare.com/containers/examples/stateless/)

[**Status Hooks**Execute Workers code in reaction to Container status changes](https://4f1c5cd2.previews.developers.cloudflare.com/containers/examples/status-hooks/)

[**Websocket to Container**Forwarding a Websocket request to a Container](https://4f1c5cd2.previews.developers.cloudflare.com/containers/examples/websocket/)

Was this helpful?

YesNo

## On this page

[![](https://4f1c5cd2.previews.developers.cloudflare.com/_astro/logo.te5VL_aD.svg)Docs](https://4f1c5cd2.previews.developers.cloudflare.com/)

```json
{"@context":"https://schema.org","@type":"WebPage","@id":"https://developers.cloudflare.com/containers/examples/#page","headline":"Examples · Cloudflare Containers docs","description":"Code examples showing how to use Containers with Workers for stateless routing, cron jobs, WebSockets, and more.","url":"https://developers.cloudflare.com/containers/examples/","inLanguage":"en","image":"https://developers.cloudflare.com/og-docs.png","dateModified":"2026-08-25","publisher":{"@type":"Organization","name":"Cloudflare","description":"One platform for your apps, agents, and workforce. Build, secure, and scale without managing infrastructure","url":"https://www.cloudflare.com/","sameAs":["https://github.com/cloudflare","https://www.linkedin.com/company/cloudflare","https://x.com/cloudflare"],"logo":{"@type":"ImageObject","url":"https://developers.cloudflare.com/logo.svg"},"address":{"@type":"PostalAddress","streetAddress":"101 Townsend St","addressLocality":"San Francisco","addressRegion":"CA","postalCode":"94107","addressCountry":"US"},"contactPoint":[{"@type":"ContactPoint","contactType":"Customer Support","url":"https://support.cloudflare.com/","availableLanguage":["English"]},{"@type":"ContactPoint","contactType":"Sales","url":"https://www.cloudflare.com/contact/","availableLanguage":["English"]}]},"isPartOf":{"@type":"WebSite","@id":"https://developers.cloudflare.com/#website","name":"Cloudflare Docs","url":"https://developers.cloudflare.com/"}}
```
