YouTube PubSubHubbub (WebSub): How It Works, and When to Run It Yourself

YouTube still runs a public PubSubHubbub hub — renamed WebSub, same protocol — that pushes a notification shortly after a channel publishes. It's free, and it's real. It's also more plumbing than it looks: a public callback, a verification handshake, and a subscription that quietly expires every few days if nothing renews it. This page lays out exactly what the DIY path involves and where a hosted webhook trades push latency for less to maintain. TranscriptHook doesn't use WebSub itself — it polls YouTube's RSS feed — and we say so plainly below.

What YouTube's PubSubHubbub push notifications are

YouTube can tell your server when a channel publishes, so you don't have to keep checking. Google's own push notifications guide describes it as a server-to-server publish/subscribe protocol: you subscribe to a channel's feed at Google's hub, and the hub sends an HTTP POST to your server when something changes. It uses the open PubSubHubbub protocol, now standardised by the W3C as WebSub. Same thing, two names.

What you need to know

  • Hub: https://pubsubhubbub.appspot.com. You send subscribe requests to its /subscribe endpoint.
  • Topic URL: https://www.youtube.com/xml/feeds/videos.xml?channel_id=CHANNEL_ID. One topic per channel.
  • Callback URL: a public HTTPS endpoint you host. The hub first sends it a verification request (hub.challenge) that you must echo back, then POSTs notifications to it.
  • What triggers a notification: a new upload, or a change to a video's title or description. That is why one video can notify you more than once.
  • What arrives: a small Atom XML entry with the video ID, channel ID, title, link, author, and published and updated timestamps. No transcript, no captions.
  • No API key, no quota: it is not part of the Data API's 10,000-unit daily budget, and you do not need a Google Cloud project.

Subscribing is one form post, and answering the handshake is a few lines of code. We walk through both, with copy-paste examples, in the YouTube webhook guide. Google's page stops there, though. It does not cover the lease, signatures or what happens when your callback is down, and those are what decide whether running it yourself is worth it. The rest of this page covers them.

Google's open protocol

PubSubHubbub / WebSub

A push notification hub. Subscribe to a channel's topic URL and the hub POSTs a small Atom entry to your callback the moment that channel publishes or edits a video. Free, no API key — but the plumbing is yours.

  • Near-real-time push notification
  • Requires a public HTTPS callback endpoint
  • You verify the hub's challenge request
  • Subscription lease expires (~5 days) and must be renewed
  • Notification only — video ID, title, channel, no transcript
  • Duplicate entries on edits — dedup is on you
TranscriptHook

Hosted Webhook Delivery

Not a WebSub client — TranscriptHook polls each channel's public RSS feed about every 10 minutes and POSTs the new video, transcript included, to a URL you control. No callback to host, no lease to renew.

  • Polls about every 10 minutes (Free accounts can take up to about 20)
  • No public callback or hub handshake to run
  • Nothing to renew — there's no subscription to expire
  • Full transcript included in the webhook payload
  • Exactly-once delivery per subscription, even across overlapping poll runs
  • Delivery retries with backoff (3 quick retries, then up to 5 more over about a day) before a failure is logged

What building PubSubHubbub yourself actually involves

Subscribing to the hub is genuinely one HTTP form post. What comes after that is the part that decides whether this is a good use of a week.

1. The lease expires — and fails silently

Google's hub caps hub.lease_seconds at 432,000 seconds — five days. When a subscription lapses, notifications simply stop. Nothing errors, nothing logs, and there's no callback telling you the lease is gone. The integration looks fine until someone notices a channel has been quiet for a week that it clearly wasn't. You need a scheduled renewal job, and that job has to be more reliable than the thing it's renewing.

2. You still don't get the transcript

The hub's payload is a few lines of Atom: a video ID, a title, a channel ID, two timestamps. That's it. If what you actually want is the spoken content of the video — for a RAG pipeline, a summarizer, a monitoring tool — the notification is just the starting gun. Fetching captions is a separate job, and it's the one that fights back: YouTube blocks caption requests from data-center IP ranges, so code that works from a laptop returns empty from Render, Fly, or AWS.

3. Push is faster, but polling is simpler to run

A public callback needs to stay reachable indefinitely — a URL that 500s for long enough gets dropped by the hub. It has to survive redeploys, and it has to answer the verification handshake with the exact challenge string, echoed back as plain text, or the subscription silently fails. Polling a feed has none of that: no inbound traffic to secure, no handshake, no lease clock. The tradeoff is latency, not correctness — polling is some minutes behind push, not more likely to break.

None of this is exotic — it's a few hundred lines and an afternoon to get subscribed. The part that costs ongoing time is the renewal cron, the edit-triggered duplicates, and the transcript fetch, and those don't go away once you ship; they're what you maintain for as long as the integration exists.

TranscriptHook polls RSS — it does not subscribe to the WebSub hub

We want to be direct about this rather than let the comparison imply otherwise: TranscriptHook does not implement PubSubHubbub or WebSub. It monitors each subscribed channel's public RSS feed about every 10 minutes (Free accounts can take up to about 20). That is a real, honest tradeoff against the hub's near-instant push, not a hidden one.

What polling buys back is everything the hub payload doesn't give you. Because TranscriptHook already owns the fetch step, it fetches the transcript through a residential-IP proxy chain before delivering the webhook — the same captions request that returns empty from a data center. The payload arrives as one POST with the video metadata and the full transcript together, not a bare notification you then have to go fetch content for.

If some minutes of delay is acceptable and you want the transcript in the same request that tells you a video exists, polling with delivery built around it is the simpler system — not because push is bad, but because push only solves the notification, and the notification was never the hard part.

Delivery guarantees, not just a POST

The hub's own delivery to your callback carries no documented retry or dedup contract for you to rely on — you build both. TranscriptHook's poller claims each delivery against a unique (subscription, video) row before it POSTs, so a video is never delivered twice to the same subscription even if two poll cycles overlap. A failed delivery is retried three times with backoff (2s, 10s, 30s) before it's recorded as failed and an admin alert fires.

By default, delivery also waits until the transcript is confirmed available (or a 24-hour hold expires) before firing your webhook, so you're not handed a payload racing an empty transcript field — that's configurable per subscription if you'd rather get the notification immediately.

Side by side

Capability PubSubHubbub / WebSub (DIY) TranscriptHook
Notification Delivery
Notification latency ✓ Near real-time push Polling about every 10 min (Free up to about 20)
Public HTTPS callback required ✕ Required ✓ None needed
Hub verification handshake to implement ✕ Required ✓ N/A
Subscription renewal required ✕ Every ~5 days ✓ Nothing to renew
Duplicate notifications on video edits ✕ Dedup is yours to build ✓ Handled — exactly-once per video
Content
Transcript included in the notification ✕ Metadata only ✓ Full transcript + segments
Works from a data-center IP Notification: yes. Captions: no ✓ Residential proxy chain
AI summary + key takeaways ✕ ✓ Pro / Agency
Keyword filtering on transcript content ✕ ✓
Reliability & Ops
Delivery retries on your endpoint failing No documented SLA from the hub ✓ Retries with backoff over about a day
Hold delivery until transcript is confirmed ✕ N/A — no transcript ✓ Optional, per subscription
Silent-failure risk if unmaintained ✕ Lease expiry is silent ✓ No lease to let lapse
Setup & Cost
Requires a Google Cloud project or API key No No
Requires hosting a public server Required No
Free to use ✓ Free ✓ Free tier — 1 channel + 10 transcript lookups/mo

They solve different halves of the same problem

Subscribe to the hub yourself when the notification is genuinely all you need — you want to know a video exists, near-instantly, and you're comfortable owning a public callback, a renewal cron, and dedup logic for the life of the integration. It's free, it works, and for a small side project that's a fair trade.

Reach for a hosted webhook when what you actually want is the transcript, not just the notification — and you'd rather not run a public endpoint or track a five-day expiry clock to get it. TranscriptHook trades the hub's near-instant push for a short polling delay, and uses that same fetch step to hand you the transcript in the same payload.

Build PubSubHubbub/WebSub yourself when a bare, near-instant new-video notification is the whole requirement.

Use TranscriptHook when you want the transcript delivered with the notification, without hosting a callback or renewing a subscription.

PubSubHubbub for YouTube — FAQ

What are the hub URL and topic URL for YouTube PubSubHubbub?
The hub is https://pubsubhubbub.appspot.com, and subscriptions go to its /subscribe endpoint. The topic URL for a channel is https://www.youtube.com/xml/feeds/videos.xml?channel_id=CHANNEL_ID. Replace CHANNEL_ID with the channel's ID, which starts with UC.
What events does YouTube send through PubSubHubbub?
Per Google's documentation: a channel uploading a video, and a video's title or description being updated. Each notification is an Atom entry with the video ID, channel ID, title, link, author, and published and updated timestamps. Because edits also trigger a notification, expect repeat entries for the same video and deduplicate on the video ID.
What is PubSubHubbub for YouTube?
PubSubHubbub is a push protocol YouTube uses to announce new and updated videos in near-real time. Instead of polling a channel's feed, you subscribe to a hub, and the hub POSTs a small Atom entry to a callback URL you host whenever that channel publishes. It was renamed WebSub when it became a W3C recommendation — both names refer to the same hub and the same feature.
How do I get notified when a YouTube channel uploads a new video?
Two options. Subscribe to YouTube's own PubSubHubbub/WebSub hub yourself — free, but you host a public HTTPS callback, answer a verification challenge, and re-subscribe roughly every five days before the lease expires. Or use a hosted webhook API like TranscriptHook, which polls each channel's RSS feed about every 10 minutes and POSTs the new video, transcript included, to a URL you provide — no callback to host and no renewal to track, in exchange for some minutes of polling delay instead of near-instant push.
Is YouTube's WebSub hub still supported?
Yes. Google still runs the hub and YouTube still publishes every new video to it, with no announced deprecation. The PubSubHubbub name persists mostly because that's what people search for — the current spec name is WebSub.
PubSubHubbub vs a hosted webhook API — what's the real difference?
Latency versus maintenance. PubSubHubbub pushes near-instantly but leaves you to host a public callback, verify the hub's challenge, renew the subscription before each lease expires, deduplicate re-published entries, and fetch the transcript yourself — the hub payload carries no captions. A hosted webhook API trades that near-instant push for a short polling interval, and handles renewal, deduplication, and transcript delivery for you instead.
Does TranscriptHook use PubSubHubbub or WebSub?
No. TranscriptHook monitors channels by polling YouTube's public RSS feed about every 10 minutes, rather than subscribing to the WebSub hub. That trades the hub's near-instant push for a short, predictable delay, and it's what lets TranscriptHook fetch and attach the transcript before delivering the webhook, something the WebSub payload itself never includes.

Want the transcript, not just the ping?

TranscriptHook watches the channels and POSTs each new video with its full transcript to your URL. Or connect it to Claude and ask about new videos in chat. Free tier, no credit card, no public server to host.

No credit card · Free tier forever