A modern, self-hosted, single-tenant bookmark manager inspired by Shaarli. Built with Laravel 12, React, Mantine UI, and Inertia.js.
- Bookmark Management - Save, organize, and search your bookmarks
- Full-Text Search - Fast search powered by SQLite FTS5 or PostgreSQL tsvector
- OpenGraph Thumbnails - Automatically fetches og:image from bookmarked URLs for visual previews
- Bookmarklet - Quick-add bookmarks from any page with a browser bookmarklet
- Shaarli Migration - Three import methods: API, Database file, or HTML export
- Export - Download bookmarks as HTML (Netscape format) or JSON
- Legacy URL Support - 301 redirects from old Shaarli URLs (
/shaare/{hash}) - Atom Feed - Subscribe to your bookmarks at
/feed - Social Sharing - Optional auto-posting to Twitter, Mastodon, and Bluesky
- Dashboard - Stats and visualizations of your bookmark collection
- Cozy Theme - Warm, paper-textured aesthetic with automatic dark/light mode
- Backend: Laravel 12, PHP 8.4+, Laravel Actions
- Frontend: React 18, TypeScript, Mantine 8, Inertia.js with SSR
- Database: SQLite or PostgreSQL (both fully supported)
- PHP 8.4+
- Node.js 20+
- Composer
- SQLite or PostgreSQL
# Clone the repository
git clone https://github.com/your-username/gongyu.git
cd gongyu
# Install dependencies
composer install
npm install
# Configure environment
cp .env.example .env
php artisan key:generate
# Run migrations
php artisan migrate
# Build frontend assets
npm run build
# Start the server
php artisan serveRun all services concurrently:
composer run devThis starts:
- Laravel development server
- Queue worker
- Log viewer (Pail)
- Vite dev server with HMR
This project uses Husky for Git hooks. After running npm install, a pre-commit hook is automatically set up that runs composer check:
- Pint - PHP code style (Laravel preset)
- PHPStan - PHP static analysis
- Biome - TypeScript/React linting and formatting
To manually run checks:
# Check for issues
composer check
# Auto-fix formatting
composer lint- Visit
/setupto create your admin account (only available when no users exist) - Log in at
/login - Configure your bookmarklet in Settings
- Optionally configure social media credentials for auto-sharing
Go to Settings > Import to migrate your bookmarks. Three methods are available:
- In Shaarli, go to Tools > Configure your Shaarli > REST API
- Copy your API secret
- Enter your Shaarli URL and API secret in Gongyu
- Click Import
- Locate
data/datastore.phpin your Shaarli installation - Upload the file in Gongyu
- In Shaarli, go to Tools > Export
- Export as HTML (Netscape bookmark format)
- Upload the HTML file in Gongyu
Note: API and Database imports preserve legacy Shaarli URLs (
/shaare/{hash}), enabling automatic redirects. HTML import does not preserve these URLs.
Go to Settings > Import > Restore from Backup to restore bookmarks from a Gongyu JSON export. This preserves all data including short URLs, Shaarli legacy URLs, and thumbnails.
Go to Settings > Export to download your bookmarks:
- HTML: Netscape bookmark format (compatible with browsers and Shaarli)
- JSON: Full data backup with all fields
See docs/self-hosting.md for Docker deployment instructions.
- Atom Feed:
/feed- All public bookmarks in Atom format - Single Bookmark:
/b/{shortUrl}- View a single bookmark - Legacy Shaarli:
/shaare/{hash}- Redirects to new URL
MIT