TiloBox
Back to directory
ntfy project preview

ntfy

A publish-subscribe notification service that accepts HTTP requests and delivers messages to web, desktop, and mobile clients.

LicenseApache-2.0
GitHub stars33.7k
Last commit1 weeks ago
Tags6 topics
Http ApiPush NotificationsGoSelf HostedOpen SourceDeveloper Tools
Overview

Why consider ntfy?

ntfy (pronounced "notify") is an open-source, self-hostable HTTP-based pub/sub notification service that lets you send push notifications to your phone or desktop via simple PUT/POST requests — no sign-up required.

Guided learning

Learn ntfy by building

Practical setup notes, real use cases, and copy-ready examples in one focused guide.

5 min read 6 sections
In this guide6 sections

ntfy: Send Push Notifications with a Simple HTTP Request

ntfy (pronounced notify) is a simple HTTP-based pub-sub notification service. With ntfy, you can send notifications to your phone or desktop via scripts from any computer, without having to sign up or pay any fees. If you'd like to run your own instance of the service, you can easily do so since ntfy is open source.

The free hosted version is available at ntfy.sh. There is also an open-source Android app available on Google Play or F-Droid, as well as an open-source iOS app available on the App Store.


How Publishing Works

Publishing messages can be done via HTTP PUT/POST or via the ntfy CLI. Topics are created on the fly by subscribing or publishing to them. Because there is no sign-up, the topic is essentially a password, so pick something that's not easily guessable.

Here's the simplest possible example — sending a message with curl:

bash
1curl -d "Backup successful 😀" ntfy.sh/mytopic

That's it. Anyone subscribed to ntfy.sh/mytopic — via the mobile app, the web UI, or the API — will instantly receive that notification.

You can also add a title, priority, and tags using HTTP headers:

bash
1curl \
2 -H "Title: Unauthorized access detected" \
3 -H "Priority: urgent" \
4 -H "Tags: warning,skull" \
5 -d "Remote access to phils-laptop detected. Act right away." \
6 ntfy.sh/phil_alerts

The same publish call works identically in Python:

python
1import requests
2requests.post("https://ntfy.sh/mytopic",
3 data="Backup successful 😀".encode(encoding='utf-8'))

Or as a raw HTTP request:

http
1POST /mytopic HTTP/1.1
2Host: ntfy.sh
3
4Backup successful 😀

Rich Message Features

ntfy supports a wide range of message enrichment via HTTP headers set at publish time:

HeaderPurpose
TitleCustom notification title
PriorityUrgency level: min, low, default, high, urgent
TagsComma-separated emoji shortcodes (e.g. warning,skull)
ClickURL to open when the notification is tapped
AttachURL of an image/file to attach
ActionsInline action buttons (open URL, HTTP request, broadcast)
EmailForward the notification to an email address
DelaySchedule delivery for a later time

Here is a full-featured example combining a click action, file attachment, an HTTP action button, and email forwarding:

bash
1curl \
2 -H "Click: https://home.nest.com/" \
3 -H "Attach: https://nest.com/view/yAxkasd.jpg" \
4 -H "Actions: http, Open door, https://api.nest.com/open/yAxkasd, clear=true" \
5 -H "Email: phil@example.com" \
6 -d "There's someone at the door. 🐶" \
7 ntfy.sh/mydoorbell

Self-Hosting ntfy

ntfy is fully self-hostable. The server is written in Go and ships as a single statically-linked binary with no runtime dependencies. Installation on a Linux server takes only a few minutes.

Docker (quickest method):

bash
1docker run -p 80:80 -it binwiederhier/ntfy serve

Debian/Ubuntu via apt:

bash
1sudo mkdir -p /etc/apt/keyrings
2curl -fsSL https://archive.heckel.io/apt/pubkey.txt | sudo gpg --dearmor -o /etc/apt/keyrings/archive.heckel.io.gpg
3sudo apt install -y ntfy
4sudo systemctl enable ntfy
5sudo systemctl start ntfy

Once running, your self-hosted server works exactly like ntfy.sh — you just replace the hostname. For example:

bash
1curl -d "Hello from my server" https://ntfy.myhost.com/mytopic

The server is configured via a YAML file at /etc/ntfy/server.yml. Key options include setting a base URL, enabling user authentication, configuring SMTP for email forwarding, and setting attachment storage paths.


Mobile Apps and Web UI

ntfy ships with native mobile clients and a web application:

  • Android app — available on Google Play and F-Droid (open source)
  • iOS app — available on the App Store (open source)
  • Web app — at ntfy.sh/app, also installable as a PWA for desktop notifications

On mobile, you subscribe to a topic name. Any message published to that topic (from curl, a script, or another app) appears as a push notification on your device — no polling required.


ntfy Pro and Sponsorship

The hosted service at ntfy.sh is free. For users who don't want to self-host or want to support the project, paid plans are available starting at $5/month (→ Purchase via web app). You can also donate via GitHub Sponsors or Liberapay.


Summary

ntfy is the simplest way to wire push notifications into any script, cron job, CI pipeline, or homelab workflow. Its pub/sub model, zero-signup free tier, rich header-based API, and fully open-source self-hostable server make it a practical choice for developers who want reliable notifications without vendor lock-in.

Related tools

More options with a similar category or technology profile.

ntfy FAQs

ntfy is listed as a Communication tool on TiloBox. Review the overview, features, and official documentation on this page to decide whether it solves your specific workflow.

Start with the project's GitHub repository and official website for supported installation and deployment instructions. Test the setup with representative data or a small project before rolling it out more widely.

ntfy is listed under the Apache-2.0 license. Read the complete license text and the project's notices before using, modifying, or distributing the software.

Production readiness depends on your requirements. Review maintenance activity, security practices, documentation, backup and upgrade procedures, and compatibility with your stack; then validate it in a non-production environment.

ntfy is listed as an alternative to Pushover. Compare the core workflow, deployment model, integrations, and licensing against your must-have requirements before switching.