Skip to content
المشاريع

حول

Runlight is free and open-source analytics that runs inside your own app and keeps every number in your own database. It takes one package and one route to set up, and its script is under 2 KB gzipped. It sets no cookies and stores nothing personal.

البيانات والتحليلات

كيف تُقاس هذه الأرقام

النمو المقاس للنجوم

خلال 24 ساعة
٠
خلال 7 أيام
+١
خلال 15 يومًا
+١١
خلال شهر
جارٍ جمع السجل

تغيّر صافي النجوم خلال فترات متداخلة، وليس مجموعًا يوميًا. تبقى القياسات المفقودة فارغة. النجوم تقيس الاهتمام لا جودة البرمجيات.

README.md

الأصل

Runlight

Free, open-source, and privacy-friendly web analytics that you run yourself inside the app or CMS you already run.

Runlight counts visitors without cookies and without storing anyone’s IP address, so there is no consent banner to show. Your numbers stay in your own database, and the dashboard is served from your own domain. The tracking script is under 2 KB gzipped.

Website · Documentation · Changelog

What you get

  • Visitors, pages, sources, countries, devices, and campaigns, over any period you choose.
  • Goals and the revenue they bring, funnels, and the paths visits take through your site.
  • AI agents such as ChatGPT and Claude counted when they read your pages, and checked against the addresses their companies publish.
  • Short links on your own domains, with their clicks counted.
  • Weekly or monthly email reports, and a read-only dashboard you can share by link.
  • An assistant that answers questions about your numbers and prepares goals, funnels, email reports, share links, and member invitations for you to review and confirm in chat. The MCP server for AI apps remains read-only.
  • Imports of your history from Plausible, Umami, or a CSV file, and of short links from Umami, Bitly, Dub, Rebrandly, Short.io, or a CSV file.

Get started

Inside an app you already have

Install the library, mount its routes, and add one script tag. Your stats are at /runlight.

npm install @runlight/sdk better-sqlite3

It works with Next.js, Nuxt, SvelteKit, Astro, Remix, Express, NestJS, Fastify, Koa, Hono, and anything else that handles a web Request, on Node 22 or later, Bun, Deno, or Cloudflare Workers. It stores its data in SQLite, Postgres, MySQL, MariaDB, Turso, or Cloudflare D1. The install guide has a section for each framework.

As a server of its own

The standalone server suits sites that are not Node apps, and gives any number of sites one dashboard, with sign-in for the people you invite.

npx @runlight/server

Or with Docker:

docker run -d --name runlight -p 3000:3000 -v runlight:/data ghcr.io/runlightsh/runlight

See the standalone server docs for running it behind a proxy, on a domain, and with Postgres or MySQL. For a very busy site, it can keep the visits and events in ClickHouse.

Other languages and platforms

Runlight is also available for eight more languages and three CMSs. Each language serves the same dashboard and uses the same tables, so you can switch between them without losing your data.

Platform Install Docs
PHP composer require runlight/runlight (PHP 8.2 or later) PHP
WordPress From WordPress.org: wp plugin install runlight --activate, or search for Runlight under Plugins, Add New WordPress
Drupal From drupal.org: composer require drupal/runlight, then drush pm:install runlight (Drupal 10.3, 11, or 12) Drupal
Craft CMS From the Plugin Store, or composer require runlight/craft, then php craft plugin/install runlight (Craft 5.3 or later) Craft CMS
Python pip install runlight (Python 3.11 or later), with the postgres or mysql extra for those databases Python
Rails bundle add runlight, then bin/rails generate runlight:install and bin/rails db:migrate (Rails 8.0 or 8.1) Rails
Ruby bundle add runlight sqlite3 (Ruby 3.2 or later), or pg, trilogy, or mysql2 in place of sqlite3 Ruby
Go go get runlight.sh/go (Go 1.25 or later), with runlight.sh/go/chi or runlight.sh/go/echo for those routers Go
Java sh.runlight:runlight from Maven Central (Java 21 or later), with runlight-servlet or runlight-spring-boot-starter Java
.NET dotnet add package Runlight.AspNetCore (.NET 10 or later), or dotnet tool install --global Runlight.Server for the standalone server .NET
Elixir {:runlight, "~> 0.6"} in mix.exs (Elixir 1.18 or later) Elixir
Rust cargo add runlight --features axum and cargo add runlight-sqlx --features sqlite (Rust 1.88 or later, and 1.94 or later for runlight-sqlx) Rust

The WordPress, Drupal, and Craft plugins add the script to your site and report AI agents that read its pages. They send to your own Runlight, wherever you run it.

Runlight for Mac

Runlight for Mac is a free menu bar app for macOS 14 or later. It shows today’s visitors for every site, with the change against the same time yesterday, and sends an alert when a site suddenly gets busy. It connects to your own Runlight with a read-only token and only reads: a site’s goals, links, and settings open in your dashboard, where you change them. Download it from the Mac page, or install it with Homebrew:

brew install --cask runlightsh/tap/runlight

Its code is on GitHub under the MIT license, and the Mac app docs explain how to connect it.

Privacy

Runlight never sets a cookie on your visitors and never stores an IP address or a full user agent. Visitors are counted with a hash whose random salt changes every day and is deleted after its day is over and the last visit that began that day has ended, at the next visit or hourly check, so it cannot be reversed. A visitor lasts one day, or until a visit that runs past midnight ends. The hash stays with each visit, but once its salt is gone it cannot be recomputed or matched to anyone's later visits. Page paths, titles, and event properties are kept as your site sends them, so keep personal details out of them. Read how Runlight counts for the details.

Contributing

Bug reports and pull requests are welcome. CONTRIBUTING.md explains how the repository is laid out and how to run the tests.

License

MIT

استكشف مشاريع مشابهة ومرتبطة

جارٍ التحميل…