<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/dynamic-routing-with-cel-interpolation-zysw6mkaq" -->

---
title: Dynamic routing with CEL interpolation | daily.dev
description: Ngrok's Traffic Policy now supports CEL (Common Expression Language) interpolation in the url field of its forward-internal action, letting requests be routed...
canonical: https://daily.dev/posts/dynamic-routing-with-cel-interpolation-zysw6mkaq
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: Dynamic routing with CEL interpolation | daily.dev
og:description: Ngrok's Traffic Policy now supports CEL (Common Expression Language) interpolation in the url field of its forward-internal action, letting requests be routed...
og:url: https://daily.dev/posts/dynamic-routing-with-cel-interpolation-zysw6mkaq
og:image: https://api.daily.dev/og/posts/Zysw6mkaq.png
og:image:alt: Dynamic routing with CEL interpolation
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Dynamic routing with CEL interpolation

**[ngrok Blog](https://daily.dev/sources/ngrok)** · 3 min read · 0 upvotes · 0 comments

## Summary

Ngrok's Traffic Policy now supports CEL (Common Expression Language) interpolation in the url field of its forward-internal action, letting requests be routed dynamically based on attributes like host, path, query string, and headers. Examples include extracting a subdomain to route to a matching internal endpoint, routing SaaS traffic to per-customer internal networks using custom headers, and routing to individual developer machine environments through a single public endpoint.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://ngrok.com/blog/dynamic-routing-cel>

## Questions this post answers

### How can I use ngrok's Traffic Policy to route requests to different internal endpoints based on the subdomain?

Ngrok now supports CEL interpolation in the url field of the forward-internal action, so you can extract the subdomain from the req.host variable and route dynamically. For example, on a wildcard endpoint like *.example.org, a request to blog.example.org can be forwarded to blog.internal automatically, without creating a separate rule per subdomain.

_Teams building multi-tenant routing setups can track ngrok Traffic Policy updates like this one on daily.dev._

### How do I route SaaS traffic to different customer networks without managing hundreds of separate endpoints?

Ngrok's CEL interpolation in the url configuration field lets you route based on request attributes such as a custom header instead of hardcoding an endpoint per customer. You set up internal endpoints per customer, such as CUSTOMER_1.YOUR_DOMAIN.internal, and forward requests from a single public endpoint using a header like X-Customer-Value to pick the right target.

_Engineers scaling per-customer connectivity can follow routing patterns like this via daily.dev._

## Similar posts on daily.dev

- [AWS ALBs Now Support Native URL and Host Header Rewriting](https://daily.dev/posts/aws-albs-now-support-native-url-and-host-header-rewriting-pcpzxll2q) · InfoQ · 0 upvotes · 0 comments
- [Building a native C\# implementation of CEL engine](https://daily.dev/posts/building-a-native-c-implementation-of-cel-engine-wk392nkpt) · Hacker News · 0 upvotes · 0 comments
- [From Static Rules to Dynamic Intent: Network Policy with Cilium matchExpressions](https://daily.dev/posts/from-static-rules-to-dynamic-intent-network-policy-with-cilium-matchexpressions-qfjdzqjnf) · Isovalent · 1 upvotes · 0 comments

---

Tags: [#devtools](https://daily.dev/tags/devtools), [#api-gateway](https://daily.dev/tags/api-gateway)

[View this post on daily.dev](https://daily.dev/posts/dynamic-routing-with-cel-interpolation-zysw6mkaq)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"Dynamic routing with CEL interpolation","url":"https://daily.dev/posts/dynamic-routing-with-cel-interpolation-zysw6mkaq","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/dynamic-routing-with-cel-interpolation-zysw6mkaq"},"datePublished":"2026-08-23T07:21:15.486Z","dateModified":"2026-08-23T07:27:29.354Z","description":"Ngrok's Traffic Policy now supports CEL (Common Expression Language) interpolation in the url field of its forward-internal action, letting requests be routed...","image":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/8a3b03f7948bf9cdbe27b9eca2c095f9?_a=AQAEuop","thumbnailUrl":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/8a3b03f7948bf9cdbe27b9eca2c095f9?_a=AQAEuop","isAccessibleForFree":true,"articleSection":"ngrok Blog","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"ngrok Blog","logo":"https://media.daily.dev/image/upload/s--718XXxvE--/f_auto,q_auto/v1787469610/logos/ngrok?_a=BAMAMicg0","url":"https://daily.dev/sources/ngrok"},"commentCount":0,"discussionUrl":"https://daily.dev/posts/dynamic-routing-with-cel-interpolation-zysw6mkaq","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":0},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"keywords":"devtools,api-gateway","timeRequired":"PT3M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"ngrok Blog","item":"https://daily.dev/sources/ngrok"},{"@type":"ListItem","position":3,"name":"Dynamic routing with CEL interpolation"}]}
{"@context":"https://schema.org","@type":"FAQPage","@id":"https://daily.dev/posts/dynamic-routing-with-cel-interpolation-zysw6mkaq#faq","mainEntity":[{"@type":"Question","name":"How can I use ngrok's Traffic Policy to route requests to different internal endpoints based on the subdomain?","acceptedAnswer":{"@type":"Answer","text":"Ngrok now supports CEL interpolation in the url field of the forward-internal action, so you can extract the subdomain from the req.host variable and route dynamically. For example, on a wildcard endpoint like *.example.org, a request to blog.example.org can be forwarded to blog.internal automatically, without creating a separate rule per subdomain. Teams building multi-tenant routing setups can track ngrok Traffic Policy updates like this one on daily.dev."}},{"@type":"Question","name":"How do I route SaaS traffic to different customer networks without managing hundreds of separate endpoints?","acceptedAnswer":{"@type":"Answer","text":"Ngrok's CEL interpolation in the url configuration field lets you route based on request attributes such as a custom header instead of hardcoding an endpoint per customer. You set up internal endpoints per customer, such as CUSTOMER_1.YOUR_DOMAIN.internal, and forward requests from a single public endpoint using a header like X-Customer-Value to pick the right target. Engineers scaling per-customer connectivity can follow routing patterns like this via daily.dev."}}]}
```

