Webhook Notification Plugin for YOURLS
July 14, 2026 ยท View on GitHub
Sends a JSON POST webhook notification immediately when a new shortened link is successfully created. This is designed to integrate YOURLS with Home Assistant, Discord, Slack, Node-RED, or any custom API.
Features
- Automated Webhooks: Fires a POST request immediately after a new redirect is created.
- Custom Authorization/Headers: Supports a simple token authorization value (defaulting to the
Authorizationheader) or custom header mappings (e.g.X-HA-Access: your-token). - Standard Payload: Contains complete metadata for the created link.
Screenshots
Screenshot(s)
| Webhook Notification Settings |
|---|
![]() |
Installation
- Copy or move the
webhookdirectory into your YOURLSuser/plugins/directory. - Go to your YOURLS Administration Panel and navigate to Plugins.
- Locate Webhook Notification and click Activate.
Settings & Configuration
Navigate to Webhook Notification Settings in the admin sidebar navigation menu to configure the following settings:
| Setting Option | Type | Default Value | Description |
|---|---|---|---|
Webhook URL | String | "" | The destination URL to send HTTP POST requests to (e.g. https://your-api.com/webhook). |
Authorization / Custom Header | String | "" | Optional authorization key. Entering a token defaults to the Authorization header. Enter HeaderName: value to send custom headers. |
Payload Format (JSON)
{
"event": "link_created",
"keyword": "example",
"short_url": "https://sho.rt/example",
"long_url": "https://example.com/some/destination/page",
"title": "Example Page Title",
"timestamp": "2026-07-11 22:30:00",
"ip": "192.168.1.50"
}
Home Assistant Integration Example
To catch these notifications in Home Assistant:
- Configure an automation in Home Assistant using the
webhooktrigger. - In the YOURLS Webhook settings, set the Webhook URL to:
https://<your-homeassistant-url>/api/webhook/<your_webhook_id> - Set your access headers if your Home Assistant instance is protected.
- You can access the payload fields (e.g.,
trigger.json.short_urlortrigger.json.long_url) directly in your automation actions.
Authors
- Bluscream
- Antigravity.AI
Other Plugins
Check out our other YOURLS plugins:
- Manage Protocols: Add, view, toggle, and delete allowed URL protocols.
- Prune Inactive Links: Automatically deletes old links that receive no clicks.
- Public Shortener Front Page: A premium, Turnstile-secured public URL shortener.
- Modern Clicks Log Viewer: Responsive table of click logs with GeoLite2 geolocation.
AI Disclaimer
This plugin was created and is maintained with the assistance of Antigravity, an agentic AI coding assistant by Google DeepMind.
