Tags as Code

Modern tag management for developers. TypeScript-first, Git-native, and blazingly fast. No web UI required.

Get Started View Commands
$ curl -fsSL https://yourtm.dev/install | bash

Why YourTM?

Built for developers who want control, speed, and simplicity.

TS

TypeScript First

Write tags in TypeScript with full type safety, autocomplete, and compile-time validation. No more string-based code editors.

Git

Git Native

Your tags live in your repo. Use branches for features, PRs for review, and CI/CD for deployment. Git is your database.

5KB

Tiny Runtime

~5KB total bundle size vs GTM's 50-80KB. Zone-based chunking loads only what's needed per page.

CF

Edge Deployed

Deploy to Cloudflare Workers for global edge delivery. Sub-millisecond latency, 99.99% uptime, infinite scale.

CLI

CLI Powered

Everything from the command line. Create, build, test, deploy, rollback. Integrates with any CI/CD pipeline.

V

Type-Safe Variables

Define reusable data points once. Resolve dataLayer, cookies, and URL parameters with full TypeScript support.

50+

Built-in Templates

Templates for GA4, Meta Pixel, TikTok, LinkedIn, and more. Interactive wizard creates production-ready tags.

Write Tags in TypeScript

Real code, real types, real developer experience.

yourtm/tags/ga4-pageview.ts
import { defineTag } from '@yourtm/core'

export default defineTag({
  name: 'GA4 Pageview',
  description: 'Track page views in Google Analytics 4',
  triggers: ['page-load'],
  zones: ['global'],
  consent: ['analytics'],

  // One-time setup (loads gtag.js)
  async setup() {
    await loadScript('https://www.googletagmanager.com/gtag/js?id=G-XXXXXX')
    window.gtag('js', new Date())
  },

  // Runs on every trigger
  execute(ctx) {
    window.gtag('config', 'G-XXXXXX', {
      page_title: ctx.dataLayer?.page?.title,
      page_location: ctx.url.href,
    })
  },
})

Quick Start

1

Initialize a new project

Create a new YourTM project in your current directory.

ytm init
2

Create tags from templates

Use the interactive wizard to generate tags for your platforms.

ytm create tag
3

Build your container

Compile TypeScript to optimized JavaScript bundles.

ytm build
4

Deploy to the edge

Push to Cloudflare Workers for global distribution.

ytm deploy -e production